Trying to INSERT into SQL Server DB

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Trying to INSERT into SQL Server DB

Carl Gundel-2
Hey,
 
I'm having trouble getting INSERTs to go into the database.  I have no trouble reading rows with SELECTs.
 
My code looks something like this:
 
anAbtDBConnection
  beginUnitOfWork;
  executeSQLStatement: aStatement;
  commitUnitOfWork.
 
I get no errors, and the string in aStatement executes fine if done manually using Microsoft SQL Query Analyzer.
 
Any ideas?
 
Thanks,
 
-Carl Gundel

--
You received this message because you are subscribed to the Google Groups "VA Smalltalk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at http://groups.google.com/group/va-smalltalk?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.
 
 
Reply | Threaded
Open this post in threaded view
|

Re: Trying to INSERT into SQL Server DB

jtuchel
Carl,

I once had a similar problem with DB2: I sent out several SQLs in one String (separated by semicolon), wondering why I wouldn't see any SQL codes even though it was clear that one of them had failed.

So please try and step through your snippet, making sure each of the calls was a success. INspect the results of each cascaded statement. Or better: try without cascading and see what happens.

HTH

Joachim


Am Montag, 13. Mai 2013 21:58:26 UTC+2 schrieb Carl Gundel:
Hey,
 
I'm having trouble getting INSERTs to go into the database.  I have no trouble reading rows with SELECTs.
 
My code looks something like this:
 
anAbtDBConnection
  beginUnitOfWork;
  executeSQLStatement: aStatement;
  commitUnitOfWork.
 
I get no errors, and the string in aStatement executes fine if done manually using Microsoft SQL Query Analyzer.
 
Any ideas?
 
Thanks,
 
-Carl Gundel

--
You received this message because you are subscribed to the Google Groups "VA Smalltalk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at http://groups.google.com/group/va-smalltalk?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.
 
 
Reply | Threaded
Open this post in threaded view
|

Re: Trying to INSERT into SQL Server DB

Carl Gundel-2
Hi Joachim,
 
I did step all the way into the call and there was no error.  I am not cascading anything.  :-(
 
Is there a comprehensive database programming guide for VA Smalltalk?  I cannot seem to find one.
 
Thanks,
 
-Carl

On Tuesday, May 14, 2013 10:07:56 AM UTC-4, [hidden email] wrote:
Carl,

I once had a similar problem with DB2: I sent out several SQLs in one String (separated by semicolon), wondering why I wouldn't see any SQL codes even though it was clear that one of them had failed.

So please try and step through your snippet, making sure each of the calls was a success. INspect the results of each cascaded statement. Or better: try without cascading and see what happens.

HTH

Joachim


Am Montag, 13. Mai 2013 21:58:26 UTC+2 schrieb Carl Gundel:
Hey,
 
I'm having trouble getting INSERTs to go into the database.  I have no trouble reading rows with SELECTs.
 
My code looks something like this:
 
anAbtDBConnection
  beginUnitOfWork;
  executeSQLStatement: aStatement;
  commitUnitOfWork.
 
I get no errors, and the string in aStatement executes fine if done manually using Microsoft SQL Query Analyzer.
 
Any ideas?
 
Thanks,
 
-Carl Gundel

--
You received this message because you are subscribed to the Google Groups "VA Smalltalk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at http://groups.google.com/group/va-smalltalk?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.