This website uses cookies. By clicking Accept, you consent to the use of cookies. Click Here to learn more about how we use cookies.
Turn on suggestions
Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.
- Revenera Community
- :
- InstallShield
- :
- InstallShield Forum
- :
- Partially resolved
Subscribe
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Subscribe
- Mute
- Printer Friendly Page
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Feb 03, 2010
08:35 PM
MySQL_ODBC_5.1_32Bit.msn giving error, when I try and connect
Hi,
I am trying to connect using the connection string
Dim objCnn As ADODB.Connection
'Work with the connection object.
Set objCnn = New ADODB.Connection
With objCnn
'DATABASE: Create the connection string and set the settings.
.ConnectionString = "DRIVER={MySQL ODBC 5.1 Driver};" & _
on Microsoft Windows Vista (in my test case). The active driver seems to be myodbc5.dll at v5.1.6. I see that the MSM and InstallShield script installed the files to the folder:
C:\Program Files\MySQL\Connector ODBC 5.1
I am receiving the error "[Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified".
Obviously the problem seems to be that either I am using the wrong connection string, which I doubt, as on my development machine, when I installed the driver from Sun's site, that works plus there are articles stating that that is right, i.e.
http://www.connectionstrings.com/Providers/mysql-connector-odbc-5-1
which also mentions myodbc5.dll
or the problem is that the driver was not registered properly and my VB6 application cannot find the driver (using ADODB).
What is the solution that enables me to use this redistribution module successfully?
Thanks,
Sarah.
I am trying to connect using the connection string
Dim objCnn As ADODB.Connection
'Work with the connection object.
Set objCnn = New ADODB.Connection
With objCnn
'DATABASE: Create the connection string and set the settings.
.ConnectionString = "DRIVER={MySQL ODBC 5.1 Driver};" & _
on Microsoft Windows Vista (in my test case). The active driver seems to be myodbc5.dll at v5.1.6. I see that the MSM and InstallShield script installed the files to the folder:
C:\Program Files\MySQL\Connector ODBC 5.1
I am receiving the error "[Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified".
Obviously the problem seems to be that either I am using the wrong connection string, which I doubt, as on my development machine, when I installed the driver from Sun's site, that works plus there are articles stating that that is right, i.e.
http://www.connectionstrings.com/Providers/mysql-connector-odbc-5-1
which also mentions myodbc5.dll
or the problem is that the driver was not registered properly and my VB6 application cannot find the driver (using ADODB).
What is the solution that enables me to use this redistribution module successfully?
Thanks,
Sarah.
(3) Replies
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Feb 03, 2010
10:28 PM
Okay, for posterity sake and I guess my future looking at. 😉
The problem is that the InstallShield redistributable MSM module did only part of the work. There is still another part, namely to call the installer, as such.
myodbc-installer.exe -d -a -n "MySQL ODBC 5.1 Driver" -t "DRIVER=myodbc5.dll;SETUP=myodbc5S.dll"
The above call only needs to be called once and with the proper pathing for DLLs as InstallShield does NOT install to Windows\System32. There is also the questio nof finding out in a general sense (yes, I speak of Windows 7 and 64-bit on various Windows OS) where that file is. It may not always be in "C:\Program Files\MySQL\ODBC Connector 5.1" if memory serves.
Executing the above is only once, because that gets added to the ODBC Manager. By the way, I presume the 32-bit ODBC manager and on 64-bit Windows 7 (Vista too?) there are two other ODBC managers and only one is the right one. How does that get tied to the right one? Also, will VB6 find out.
The struggle continues.
Sarah.
The problem is that the InstallShield redistributable MSM module did only part of the work. There is still another part, namely to call the installer, as such.
myodbc-installer.exe -d -a -n "MySQL ODBC 5.1 Driver" -t "DRIVER=myodbc5.dll;SETUP=myodbc5S.dll"
The above call only needs to be called once and with the proper pathing for DLLs as InstallShield does NOT install to Windows\System32. There is also the questio nof finding out in a general sense (yes, I speak of Windows 7 and 64-bit on various Windows OS) where that file is. It may not always be in "C:\Program Files\MySQL\ODBC Connector 5.1" if memory serves.
Executing the above is only once, because that gets added to the ODBC Manager. By the way, I presume the 32-bit ODBC manager and on 64-bit Windows 7 (Vista too?) there are two other ODBC managers and only one is the right one. How does that get tied to the right one? Also, will VB6 find out.
The struggle continues.
Sarah.
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Feb 03, 2010
11:33 PM
Hi Again,
I took another step forward in my quest to get mysql ODBC working. Why am I the first person to work on this topic? I would think that InstallShield, Sun, and the rest of the community would have had the installation of the driver issue long resolved and idiot proofed.
Oh well, here is another piece to the puzzle.
The utility mentioned above installs the driver in the ODBC Manager, which you can see. I saw from a forum article that these are some of the registry settings modified.
HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBCINST.INI\MySQL ODBC 3.51 Driver
Driver = C:\WINDOWS\system32\myodbc3.dll
Setup = C:\WINDOWS\system32\myodbc3S.dll
HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBCINST.INI\ODBC Drivers
MySQL ODBC 3.51 Driver = Installed
HKEY_LOCAL_MACHINE\SOFTWARE\MySQL AB\MySQL Connector/ODBC 3.51
Version = 3.51.12
HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBCINST.INI\MySQL ODBC 3.51 Driver
UsageCount = 0
I do not see any of them set. On my development machine (Windows Vista), the installer did set all these registry settings and the driver is in fact in the Windows\System32 folder as well as under the Program Files. The driver as such shows up in my ODBC Manager, which is why it works on my development machine.
On a clean virtual machine Windows Vista (I presume the same on Windows 7) with my product installed but nothing else, the files as I said are under the Program Files folder, but they are not in the Windows\System32 (which may not be necessary with proper registry settings pointing to the right place, but maybe it is. I would have to check), but there ARE NO registry settings there and it does not work and the driver (MySQL ODBC 5.1 Driver) is not listed.
Let us assume that I have it installed (with your help). That leaves the uninstall issue. If the installation goes into the ODBC Manager, then InstallShields's merge module will not on its own remove the driver from the ODBC Manager (basically registry settings) and remove the added registry settings. Simply removing the files will cause an "unable to remove files" warning. I ran into that on my own before finding the merge module.
Simply stated, it seems that at a minimum the merge module that InstallShield provides is missing the key installation step of the driver, a necessary part, and then I presume, the removal. (That is where the usage count comes into play that I saw above).
Please advise? Copying the files manually and avoiding the redistribution module has its own problems. Besides, InstallShield provides the redistribution merge module, so it should be used, just fixed to include the MySQL ODBC driver. I am looking at the registry now and there is no MySQL ODBC driver listed in the registry at all, only after that utility is run.
Please advise and Thanks,
Sarah
I took another step forward in my quest to get mysql ODBC working. Why am I the first person to work on this topic? I would think that InstallShield, Sun, and the rest of the community would have had the installation of the driver issue long resolved and idiot proofed.
Oh well, here is another piece to the puzzle.
The utility mentioned above installs the driver in the ODBC Manager, which you can see. I saw from a forum article that these are some of the registry settings modified.
HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBCINST.INI\MySQL ODBC 3.51 Driver
Driver = C:\WINDOWS\system32\myodbc3.dll
Setup = C:\WINDOWS\system32\myodbc3S.dll
HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBCINST.INI\ODBC Drivers
MySQL ODBC 3.51 Driver = Installed
HKEY_LOCAL_MACHINE\SOFTWARE\MySQL AB\MySQL Connector/ODBC 3.51
Version = 3.51.12
HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBCINST.INI\MySQL ODBC 3.51 Driver
UsageCount = 0
I do not see any of them set. On my development machine (Windows Vista), the installer did set all these registry settings and the driver is in fact in the Windows\System32 folder as well as under the Program Files. The driver as such shows up in my ODBC Manager, which is why it works on my development machine.
On a clean virtual machine Windows Vista (I presume the same on Windows 7) with my product installed but nothing else, the files as I said are under the Program Files folder, but they are not in the Windows\System32 (which may not be necessary with proper registry settings pointing to the right place, but maybe it is. I would have to check), but there ARE NO registry settings there and it does not work and the driver (MySQL ODBC 5.1 Driver) is not listed.
Let us assume that I have it installed (with your help). That leaves the uninstall issue. If the installation goes into the ODBC Manager, then InstallShields's merge module will not on its own remove the driver from the ODBC Manager (basically registry settings) and remove the added registry settings. Simply removing the files will cause an "unable to remove files" warning. I ran into that on my own before finding the merge module.
Simply stated, it seems that at a minimum the merge module that InstallShield provides is missing the key installation step of the driver, a necessary part, and then I presume, the removal. (That is where the usage count comes into play that I saw above).
Please advise? Copying the files manually and avoiding the redistribution module has its own problems. Besides, InstallShield provides the redistribution merge module, so it should be used, just fixed to include the MySQL ODBC driver. I am looking at the registry now and there is no MySQL ODBC driver listed in the registry at all, only after that utility is run.
Please advise and Thanks,
Sarah
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Aug 24, 2011
07:50 PM
I also meet this problem, but something different ,i miss some odbc words in targent machine . such as 'user' ,'password'
![](/skins/images/A5EADE085F77DE82FB3B14D6B307AE6A/responsive_peak/images/icon_anonymous_message.png)