How do i know if odbc is installed on windows?

I am a Database Developer and currently working in SQL Server Technology. I am trying to find out the ODBC driver name based on the installed SQL Server Version. Here is what I mean - Example,

We are using SQLCMD.exe to execute some scripts through our custom MSI. SQLCMD fails if it doesn't find the correct ODBC driver. Hence we need to be able to identify the correct ODBC version based on the SQL version installed, so that we can check this before installation and prompt the user to install the correct ODBC version as a prerequisite.

I have already explored the below -

  1. Windows Registry - I did not get a clear cut idea of how to identify ODBC drivers based on versions. ODBC drivers and SQL Server versions are mentioned at multiple places and either they do not match amongst themselves or with the installed SQL Server Version.
  2. Admistrative Tools -> ODBC Admistrator -> Drivers Tab SQL Server Version here do give some idea but we are unable to decode odbcad32.exe. Link - https://learn.microsoft.com/en-us/sql/database-engine/configure-windows/check-the-odbc-sql-server-driver-version-windows?view=sql-server-2017

If anyone knows anything then please render help. We need a solution using C# ( recommended ), however, if any other technology then we can have a look for its feasibility.

Thanks in advance.

How do i know if odbc is installed on windows?

jarlh

40.7k8 gold badges41 silver badges60 bronze badges

asked Oct 8, 2018 at 11:28

Windows registry is the best way to go, I'm not sure why you're seeing inconsistencies. There are two main places to look:

For 64bit: HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBCINST.INI\ODBC Drivers

For 32bit: HKEY_LOCAL_MACHINE\SOFTWARE\WOW6432Node\ODBC\ODBCINST.INI\ODBC Drivers

If you want the specific version, you will need to go up a level into the registry keys that have the same name as those listed in ODBC Drivers. For exmaple, under ODBC Drivers you have the key "ODBC Driver 17 for SQL Server" listed as installed, under ODBCINST.INI you will have a entry called "ODBC Driver 17 for SQL Server" where you can find further details.

ODBC driver versions aren't intrinsically linked to the version of SQL installed. It's absolutely possible the ODBC driver has been updated separately, and/or multiple versions are installed.

answered Oct 8, 2018 at 12:26

ApepApep

1114 bronze badges

Data Source Name (DSN) settings connect to a database on a Windows system. Any user on the system can use the DSN to connect to the database. The DSN contains the username, password and server name for the database, so it's not necessary to re-enter these login credentials each time the user wants to connect.

  1. Click the Windows "Start" button and then click "Control Panel." Click "System and Security." Click "Administrative Tools" in the list of utilities. Double-click the icon labeled "Data Sources (ODBC)." A list of DSNs display.

  2. Click the DSN you want to test. Click the "Configure" button on the right side. The configurations for the DSN display.

  3. Click the "Test Connection" button. A message labeled "Success" displays when the connection test completes.

Installing an ODBC Driver

We do not sell or distribute ODBC drivers. You must obtain ODBC drivers from another vendor.

Some basic ODBC drivers are installed automatically with Windows operating systems. However, the drivers are not configured automatically, so you must do this by using the operating system ODBC administrator privileges.

Note:  In Windows, the ODBC administrator is called Data Sources (ODBC) and is found in Control Panel > Administrative Tools.

In current versions of Windows on 64-bit platforms, the administrator is ODBC Data Sources (64-bit). There is also a 32-bit variant. But for DataConnect, 64-bit data sources are required.

Data Direct ODBC Drivers

ODBC driver vendor Merant (formerly Pioneer, Q+E, Intersolve, Microfocus) has become Data Direct Technologies, Inc. For their ODBC driver information, see http://www.datadirect.com/download/index.ssp.

To add a data source to ODBC Control Panel

1. Go to Start > Settings > Control Panel.

2. Open the ODBC icon.

3. The User DSN tab appears. Click Add.

4. The Create New Data Source window appears. Select the appropriate driver and click Finish. (If a driver for the application that you want to connect to does not appear in the list, you need to install the driver.)

5. The Data Source Setup window appears for that driver. The next step is to enter a name for the source.

Note:  From this point forward, procedure varies slightly depending on the driver. Check the documentation of your particular driver for specifics as to how to set it up.

6. Click Select.

7. The Select Database window opens. Navigate to a Navision Financials database file.

8. Click OK. Click OK again.

9. The new Data Source Name now appears in the list in the User DSN tab. The name of the driver is in parentheses next to it. Close the ODBC administrator.

You are now ready to open the integration platform and connect to the new data source.

See Also

How do I find ODBC version in Windows?

To check the ODBC SQL Server driver version (32-bit ODBC): In Administative Tools, double-click Data Sources (ODBC). Click the Drivers tab. Information for the Microsoft SQL Server entry is displayed in the Version column.

Where is my ODBC driver installed?

Step 1: Install the ODBC Driver The driver is installed in C:\Program Files .

Does Windows come with ODBC driver?

You must obtain ODBC drivers from another vendor. Some basic ODBC drivers are installed automatically with Windows operating systems. However, the drivers are not configured automatically, so you must do this by using the operating system ODBC administrator privileges.

How do I find ODBC in Windows 10?

Simply type odbc into the Cortana Search box on your Windows 10 taskbar, the ODBC Data Source tool will show up in the search result and you can click to launch. Open the Command Prompt, or press the WIN + R keys to open the Run dialog box. Type odbcad32 and press Enter.