01-23-2012 01:08 PM
I have a relatively simple VI that logs data to MySQL. It's worked fine for a few months, with a pretty trivial setup, and everyone was happy. Over the course of this past weekend, by system rebooted itself, and now my VI's can't connect to MySQL at all.
The errors are...
Error -2147467259 occurred at NI_Database_API.lvlib:DB Tools Open Connec (String).vi->NI_Database_API.lvlib:DB Tools Open Connec (Path).vi->Log_Tools.vi Possible reason(s): ADO Error: 0x80004005 Exception occured in Microsoft OLE DB Provider for ODBC Drivers: [Microsoft][ODBC Driver Manager] The specified DSN contains an architecture mismatch between the Driver and Application in NI_Database_API.lvlib:DB Tools Open Connec (String).vi->NI_Database_API.lvlib:DB Tools Open Connec (Path).vi->Log_Tools.vi
I swear didn't change a thing between the happiness of Friday afternoon and the sadness of this Monday morning! Even so, I've been having a devil of a time getting everything running again. I've even uninstalled and re-installed MySQL (twice).
Here are some details...
When I go through the dance of creating the *.udl file, the Test button on it reports success.
Suggestions anyone?
(thanks!)
Solved! Go to Solution.
01-24-2012 04:37 PM
It looks like LabVIEW is having trouble connecting to the SQL server.
I found a couple generic reasons at this link: http://forums.asp.net/t/1427297.aspx/1
This error is commonly seen when the database was never closed then tried to open again or if it times out.
Some more information would help narrow things down.
Is the SQL on the local machine or a different one? Are you using our Datalogging and Supervisory Control Module?
01-25-2012 01:30 AM
Hi!
I don't know what happened but the error seems related to the setup of a 32-bit DSN using the 64-bit ODBC Administrato.
Give a look here:
http://msdn.microsoft.com/en-us/library/ms712362%28VS.85%29.aspx
Regards,
Marco
p.s.Why did the system rebooted itself?
01-25-2012 10:34 AM - edited 01-25-2012 10:35 AM
I also found this KnowledgeBase talking about that error on a Windows 7 64-bit system: http://digital.ni.com/public.nsf/allkb/E7984C0DA0F0E65086257694005B4CB7?OpenDocument
01-26-2012 09:27 AM
Well, I got it working, with some kind support from NI. Luis Martinez and others here were good enough to point me to this link...
Error -2147467259 from Database VI on Windows 7 64-bit
http://digital.ni.com/public.nsf/allkb/E7984C0DA0F0E65086257694005B4CB7
The remaining mystery is why this was working fine before, then started to complain. I suspect it had something to do with a midnight upgrade from Microsoft which started the whole problem.
Thanks to all that contributed.
01-26-2012 09:33 AM
I bet that it was a Windows update. That's what you get for swearing that you didn't change anything!
Well I guess you technically didn't.