LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 
Reply

labsql

A question about  using  LabSQL to built database.  There is an example in the LabSQL download packet. The "insert into a table .vi"example, it said "Do not return data since this is just a insert statement".  So the "Return data?" is set "F",but why ?  I set it to "T" ,error was reported:Recordset object was closed.
  That means I can not operate on the Recordset object after using the "Insert into"command .
 (In the example the Recordset object was generated using the Connection.excution method);
Is this question clear? who can help me ?Thanks!!
0 Kudos
Message 1 of 5
(1,561 Views)
Not sure what part you're not understanding. Why you got the error, or why there's no recordset returned from an INSERT statement? You get the error because there's no recordset returned, and when you try to close it, there's nothing to close, and the interpretation was that it was closed. There's no recordset returned because, well, it's an INSERT statement, and that's the way it works.

What are you trying to do?
0 Kudos
Message 2 of 5
(1,554 Views)

Thanks,smercurio_fc, I wanna to  get the content of the tabel immediately after I insert  a record into it. But what you said helps. The connection.excute function does not return a live recordset object  after the inserting statement, is That right?

Thanks again.

0 Kudos
Message 3 of 5
(1,529 Views)
All that you need to do is to follow it up with a SELECT statement. The "Example - Fetch a Table" does this.
0 Kudos
Message 4 of 5
(1,515 Views)
Totally get it !! Thank you!
0 Kudos
Message 5 of 5
(1,507 Views)