ni.com is currently undergoing scheduled maintenance.

Some services may be unavailable at this time. Please contact us for help or try again later.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How to add data to database (not a row)

I use "db tools insert data.vi" to add a new row to the table. What if I want to add individual data? For example, say I have a 2 column table. I want to add a to column A and maybe later add b to column B (or maybe just leave column B blank).
 
Thank you very much
0 Kudos
Message 1 of 3
(2,747 Views)

To insert your values to only some of the columns you need to use the columns input, as it says in the help for the VI.

If you later want to add data to that row, you will need to use the SQL command "Update". You can either wire an SQL statement directly into the DB Tools Execute Query VI or you can build a VI similar to Insert Data which will have an additional input for the SQL "where" clause, which decides which row it needs to update.


___________________
Try to take over the world!
0 Kudos
Message 2 of 3
(2,727 Views)
It works. Thanks.
0 Kudos
Message 3 of 3
(2,705 Views)