LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

"Variant to Data" VI returns an error when reading from Access.

Using the Database Connectivity Toolset, I can WRITE to an Access Database using DB Tools Insert Data.
When I attempt to READ from the same database, the DB Tools Select Data VI returns data of type variant.
I cannot convert this data into anything useful (although I can PROBE it - so it is there!)
The VI which OUGHT to work is, I think, "Variant to Data".
But this returns error 91. Incompatible variant data type.
Any ideas how to extract data from Access???
0 Kudos
Message 1 of 3
(2,841 Views)
See the "SixType Select.vi" under database tools examples library.

A Rafiq
National Instruments
0 Kudos
Message 2 of 3
(2,841 Views)
Thanks! The info in the "Sixtypes Select" ID showed me how to get the first item in the first row. I wanted the first item in the last row, so a condition sent to the DB Tools Select Data VI to sort the database in descending order of this first column
( ORDER BY TblMainRuns.MainRunID DESC )
works fine!
Problem solved. Thanks again.
0 Kudos
Message 3 of 3
(2,841 Views)