LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

database table add

Hello,
I'm trying to get some of the database connectivity stuff working with labview 7.1.  I've had no problem adding records, dropping tables, selecting data, and a few other database operations.  The one that I can't get past is adding a table.  I've tried all sorts of different approaches, and it always gives me this error.
 
Error -2147217900 occurred at Conn Execute.vi->DB Tools Create Table.vi
Possible reason(s):
Exception occured in Microsoft JET Database Engine, Syntax error in field definition..  in Conn Execute.vi->DB Tools Create Table.vi
 
I'm using an MS Access database with a udl connection file.  Does anyone have any thoughts?
Thanks,
Pat
0 Kudos
Message 1 of 4
(3,092 Views)

One thing that might be causing that error is trying to use a reserved word for the name of a field or the table itself.  Access has hundreds of reserved words.  Could this be your problem?  One way to check is to append a prefix to the names of all your fields such as "abc_" {don't actually use the double quotes, they mean something specific by themselves}.  If this works, chances are, you were trying to name a field with one of the reserved words and Access didn't approve.

If that doesn't fix the problem, enclose a screen capture or VI.

0 Kudos
Message 2 of 4
(3,078 Views)
Crystal,
At first it didn't work to change the table name, but then I changed all the column names and it worked.  I actually had names like "Date" and "Name" which I can understand them being reserved.  Thanks a lot for the help.
Pat
0 Kudos
Message 3 of 4
(3,066 Views)
Hi Crystal,
 
Please find attached VI.
 
It works for a particular definition and not for another.
Can you suggest what can be the ideal field definition.
 
regards,
Aniket
0 Kudos
Message 4 of 4
(2,856 Views)