LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Microsoft ODBC driver manager error -2147467259 using insert into table.vi

Yes I am using ADO connections. You were right the error was of Microsoft. I was missing a step to add my test table in the ODBC data sources. I have added it under control panel->administrative tools->ODBC->system DSN and then added my file name. Now it works. Thanks Mike and Dennis for your patience and time.

timmy
0 Kudos
Message 11 of 16
(744 Views)
OK, I will try asking my questions again, and add a new one. If you really want help, answer these questions:

1. What is in the DSN? That is where the problem most likely is.
2. Have you tried putting the entire path to the database file in the DSN?

And here's the new one.

3. Does the connection work when you click the button to test it in the DSN connection dialog?

Also, I told you the changing the version of Microsoft Office would not help. This is not s problem with Access. Access is not even involved in what you are trying to do. In fact, for this process to work you don't even need Access installed on your computer.

Oh yes:

4. Have you tried it with a hardcoded connection string and bypassed the need for a DSN?

Mike...

Certified Professional Instructor
Certified LabVIEW Architect
LabVIEW Champion

"... after all, He's not a tame lion..."

For help with grief and grieving.
0 Kudos
Message 12 of 16
(740 Views)

Thanks Mike

My connection string is DSN=myDB. Yes I had given the entire path of test.mdb in the system dsn. I didn't test it in DSN connection dialogue box. I don't know much about the DataSourceName. I am writing values in Microsoft access table that’s why I was assuming that version may create problems. No I didn't test it with hardcoded string. The VI is in Labview8.5 version and access table is attached kindly take a look(change the extension from .docx to .mdb). It is in working condition now

 

timmy
Download All
0 Kudos
Message 13 of 16
(721 Views)

you may need these VI's too. Kindly download and unzip

timmy
0 Kudos
Message 14 of 16
(716 Views)
The first thing is to test it in the DSN dialog box. If it doesn't work there it won't work from LV either.

Secondly, there is no such thing as a Access database. Access is not a database management system (or DBMS). It is a development environment for creating applications that use databases. By default Access uses a DBMS called Jet that is built into Windows. That is why I said you could do what you wanted without MS office even being installed.

When I get into the office I will look at your code and the database file.

Mike...

Certified Professional Instructor
Certified LabVIEW Architect
LabVIEW Champion

"... after all, He's not a tame lion..."

For help with grief and grieving.
0 Kudos
Message 15 of 16
(714 Views)

Try using this connect string:

 

Provider=Microsoft.Jet.OLEDB.4.0;
Data Source=C:\Users\blahblah\blah\Test.mdb;
User Id=admin;
Password=;

 

Modify such that the Data Source line contains the path to the database file on your system. I verified that this string works with your code connecting to your file. Check here for another good source of information.

 

Mike...


Certified Professional Instructor
Certified LabVIEW Architect
LabVIEW Champion

"... after all, He's not a tame lion..."

For help with grief and grieving.
0 Kudos
Message 16 of 16
(702 Views)