LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

why labview dosnt connect to mysql in this example?

Hello.

I have a problem to connect with mysql. can you help me?

I make a database in my sql and I use ODBC as interface.

in labview, ADO blocks are used to connect with mysql as example attached. but, when I run this program, it dosn't work. this example is along with ADO pack.

By the way,, it dosnt get me any ID!

do you know what is the problem?

 

Best Reagards

 

 

0 Kudos
Message 1 of 8
(4,995 Views)

any one dosn't use ADO?

0 Kudos
Message 2 of 8
(4,954 Views)

it seems that, because LabSQL(ADO) is 32 bit but ODBC driver was 64bit. on the other hand, my windows is 64 bit and my labview is 32 bit!

I Confused!! 

0 Kudos
Message 3 of 8
(4,934 Views)

Can you share the VI in 2011.. I havent seen your VI but better go for UDL file for connecting to DB. From there it is easy to debug  the problem.

--------------------------------------------------------------------------------------------------------
Kudos are always welcome if you got solution to some extent.

I need my difficulties because they are necessary to enjoy my success.
--Ranjeet
Message 4 of 8
(4,927 Views)

Hi Ranjeet_Singh 

Thank you

 

I attached it in 2011. may you explain more about UDL too? my friend will work on database, he just know SQL and my SQL. these work with UDL?

 

Best Regards

0 Kudos
Message 5 of 8
(4,918 Views)

Do you get any errors when runing the code?

 

it seems that your connectionstring is very very short.

When you connect to the MySQL database, don't you use a user and a password?

 

A UDL file is the same as a connectionstring, is "kust" describes how to connect to a database, like the name, server, username, password. 

 

Do a search on google for connectionstirng and UDL, and there should be a lot of info.

Message 6 of 8
(4,899 Views)
You should also know that Windows 7 has both 32 and 64 bit database administrator programs. Use the 32 bit version if you go the dsn route. UDL files are pretty basic with database applications and your colleague should be familiar with them.
Message 7 of 8
(4,896 Views)

UDL is very basic and best way to communicate to DB. becasue here you can change the database which you need to connect to any time. I havent seen your VI but first you need to create UDL file and configure it as per your application. For there if you can test the connection that means your configuration is ok.

 

Then from VI you need to open the UDL file and check the error message. From there you can easily check what is the problem.

 

Here start from page 3-4. Let us know if any issue

--------------------------------------------------------------------------------------------------------
Kudos are always welcome if you got solution to some extent.

I need my difficulties because they are necessary to enjoy my success.
--Ranjeet
Message 8 of 8
(4,845 Views)