Home > Windows > ODBC Data Sources on 64 bit Windows

ODBC Data Sources on 64 bit Windows

February 7th, 2012 Leave a comment Go to comments

Introduction

Following on from yesterdays article on how to get the SID of a user or group using PowerShell todays article looks at ODBC Data Sources on 64 bit editions of Windows and some of the issues that can be encountered if your ODBC Data Source is created using the incorrect version of the ODBC Data Sources tool.

ODBC Data Sources on 64 bit Windows

On 64 bit editions of Windows, such as Windows Server 2008 R2 you may encounter problems with your application if you do not use the correct version of the ODBC Data Sources tool to create your data source, particularly if your application is running as a 32 bit program. 

The most common errors with ODBC Data Sources on 64 bit editions of windows are the errors ‘Data Source Name does not exist’  or ‘Data Source Name not found’ – especially when the program accessing the Data Source is a 32 bit application, the reason for this is that under 64 bit Windows there are actually 2 versions of the ODBC Data Sources tool which is used to setup ODBC Data Sources, one for 64 bit applications and one for 32 bit applications, as you will see below the location of each of these tools can also lead to confusion.

On a 64 bit machine the ODBC Data Sources tool accessible from the Administrative Tools menu will create data sources that can be accessed only by applications which are running as 64 bit applications, if your application is running as a 32 bit application on a 64 bit machine and you created your data source using the ODBC Data Sources tool from the Administrative Tools menu then your are likely to receive errors such as those listed above when you launch your application.  To resolve these errors you need to create your data source using the 32 bit version of the ODBC Data Sources tool, which can be launched from C:\Windows\SysWOW64\odbcad32.exe on 64 bit machines – as soon as you have created your data source using this version of the ODBC Data Sources tool then you should find that your 32 bit application can access your data source with no problems.

The names of the paths to the two different versions can lead to some confusion initially as the 64 bit version of the ODBC Data Sources tool is located under ‘C:\Windows\System32’ whereas the 32 bit version of the tool is located under ‘C:\Windows\SysWOW64’.

That’s all for now, if you have any questions please use the comment box below, and remember to subscribe to the RSS feed to receive updates on new articles and PowerShell scripts posted to the site.  I’ll write a new article tomorrow on how you can use Virtual Hard Drives (VHD’s) within Windows 7 to make your personal data more portable.

If you have found this post helpful please consider making a donation to keep the site running. 

Categories: Windows
  1. No comments yet.
  1. No trackbacks yet.