- Driver= Microsoft Access Driver (*.mdb *.accdb) Dbq=
- Microsoft Access Accdb Odbc Driver
- Microsoft Access Driver Mdb Accdb Odbc Drivers For Mac Windows 7
- Driver= Microsoft Access Driver (*.mdb)
- Microsoft Access Driver Mdb Accdb Odbc Drivers For Mac Free
- Microsoft Access Driver Mdb Accdb Odbc Drivers For Mac Download
Build connection strings and enumerate installed ODBC drivers (32bit and 64bit)
Even if you had a JDBC-ODBC Bridge on your Mac you would also need to have. An implementation of ODBC itself, and; an appropriate ODBC driver for the target database (ACE/Jet, a.k.a. 'Access') So, for most people, using JDBC-ODBC Bridge technology to manipulate ACE/Jet ('Access') databases is really a practical option only under Windows. The Create New Data Source dialog box opens and displays a list of installed ODBC drivers. Select Microsoft Access Driver (.mdb,.accdb) and click Finish. In the ODBC Microsoft Access Setup dialog box for your driver, enter dbdemo as the data source name. Oct 21, 2010.
Before we can build the connection string we need to ensure that the ODBC drivers are available on our system.
The Microsoft Access Driver.mdb.accdb does not appear in the ODBC Data Source Administrator dialog box when the bitness of the operating system and Microsoft Access is mismatch occurs when you setup a data source for a 32-bit Microsoft Access database using a 64-bit MATLAB.
ODBC Drivers
The standard ODBC drivers for MS Access 97 (*.mdb) and MS Excel 97 (*.xls) should be available on all Windows installations:
Microsoft Access Driver (*.mdb)
Microsoft Excel Driver (*.xls)
Microsoft Excel Driver (*.xls)
.. but the MS Office 2010 ODBC drivers for *.xlsx and *.accdb might not be installed on your system.
This means it might be required to install the drivers first, if you want to use an Excel file with the extension .xlsx or an Access file with the extension .accdb.
This means it might be required to install the drivers first, if you want to use an Excel file with the extension .xlsx or an Access file with the extension .accdb.
Autotune for adobe audition 1.5. Microsoft Access Driver (*.mdb, *.accdb)
Microsoft Excel Driver (*.xls, *.xlsx, *.xlsm, *.xlsb)
Microsoft Excel Driver (*.xls, *.xlsx, *.xlsm, *.xlsb)
Driver= Microsoft Access Driver (*.mdb *.accdb) Dbq=
Install ODBC Driver for *.accdb and *.xlsx
You can download the latest version of 'Microsoft Access Database Engine (2010)' (for MS Access and MS Excel) here:
http://www.microsoft.com/en-us/download/details.aspx?id=13255
http://www.microsoft.com/en-us/download/details.aspx?id=13255
Important: There are different drivers for 32bit and 64bit applications. If you want to build a 32bit application, then you need to install the 32bit version of the driver, because a 32bit application cannot use the 64bit driver and a 64bit application cannot use the 32bit driver!
ODBC Connection String
The connection string for MS Access and MS Excel has the following syntax:
Microsoft Access Accdb Odbc Driver
Driver={DRIVER};Dbq=FILEPATH;
We need only 2 parameter: the ODBC driver and the file path.
e.g.
e.g.
Driver={Microsoft Access Driver (*.mdb)};Dbq=C:tempsomedatabase.mdb;
Driver={Microsoft Excel Driver (*.xls, *.xlsx, *.xlsm, *.xlsb)};Dbq=C:tempsomesheet.xlsx;
Driver={Microsoft Excel Driver (*.xls, *.xlsx, *.xlsm, *.xlsb)};Dbq=C:tempsomesheet.xlsx;
The 'driver' can be different depending on the language, so it could be required to enumerate the installed drivers and search for the file extension.
e.g. 'Microsoft Excel Driver' is called 'Microsoft Excel Treiber' in German.
e.g. 'Microsoft Excel Driver' is called 'Microsoft Excel Treiber' in German.
Enumerate ODBC Drivers
The system stores a list of the installed ODBC drivers in the registry HKEY_LOCAL_MACHINE.
There are two different locations for 32bit and 64bit drivers:
There are two different locations for 32bit and 64bit drivers:
32bit: HKEY_LOCAL_MACHINESOFTWAREODBCODBCINST.INIODBC Drivers
64bit: HKEY_LOCAL_MACHINESOFTWAREWow6432NodeODBCODBCINST.INIODBC Drivers
64bit: HKEY_LOCAL_MACHINESOFTWAREWow6432NodeODBCODBCINST.INIODBC Drivers
Sample code to enumerate 32bit ODBC drivers:
using Microsoft.Win32;
using (RegistryKey reghklm = Registry.LocalMachine)
using (RegistryKey regdrivers = reghklm.OpenSubKey(@'SOFTWAREODBCODBCINST.INIODBC Drivers'))
{
if (regdrivers != null)
{
foreach (string driver in regdrivers.GetValueNames())
{
// display drivers
MessageBox.Show (driver);
}
}
}
using (RegistryKey reghklm = Registry.LocalMachine)
using (RegistryKey regdrivers = reghklm.OpenSubKey(@'SOFTWAREODBCODBCINST.INIODBC Drivers'))
{
if (regdrivers != null)
{
foreach (string driver in regdrivers.GetValueNames())
{
// display drivers
MessageBox.Show (driver);
}
}
}
Check if ODBC Driver is installed
We can build a small function to check if a specific ODBC driver (language) is available, e.g. 'Microsoft Excel Driver (*.xls, *.xlsx, *.xlsm, *.xlsb)'
using Microsoft.Win32;
private bool IsODBCDriverInstalled(string searchfor)
{
using (RegistryKey reghklm = Registry.LocalMachine)
using (RegistryKey regdrivers = reghklm.OpenSubKey(@'SOFTWAREODBCODBCINST.INIODBC Drivers'))
{
if (regdrivers != null)
{
foreach (string driver in regdrivers.GetValueNames())
{
if (driver.IndexOf(searchfor) != -1) return true;
}
}
}
return false;
}
..
// check if English(!) Excel (2010) driver is installed
string driver= 'Microsoft Excel Driver (*.xls, *.xlsx, *.xlsm, *.xlsb)';
if (IsODBCDriverInstalled(driver))
{
// driver installed
}
else
{
// driver not found
}
private bool IsODBCDriverInstalled(string searchfor)
{
using (RegistryKey reghklm = Registry.LocalMachine)
using (RegistryKey regdrivers = reghklm.OpenSubKey(@'SOFTWAREODBCODBCINST.INIODBC Drivers'))
{
if (regdrivers != null)
{
foreach (string driver in regdrivers.GetValueNames())
{
if (driver.IndexOf(searchfor) != -1) return true;
}
}
}
return false;
}
..
// check if English(!) Excel (2010) driver is installed
string driver= 'Microsoft Excel Driver (*.xls, *.xlsx, *.xlsm, *.xlsb)';
if (IsODBCDriverInstalled(driver))
{
// driver installed
}
else
{
// driver not found
}
The function returns false if e.g. the German version is installed, so it might be better to enumerate the drivers and search for the file extension '*.xlsx'.
Find Access or Excel ODBC Driver for File Extension
We just need to modify the code a bit, so that the function returns a valid driver (any language) for the given file extension.
The function returns an empty string if no valid driver was found.
The function returns an empty string if no valid driver was found.
using Microsoft.Win32;
private string GetODBCDriverForExtension(string extension)
{
using (RegistryKey reghklm = Registry.LocalMachine)
using (RegistryKey regdrivers = reghklm.OpenSubKey(@'SOFTWAREODBCODBCINST.INIODBC Drivers'))
{
if (regdrivers != null)
{
foreach (string driver in regdrivers.GetValueNames())
{
if (driver.IndexOf(extension) != -1) return driver;
}
}
}
return ';
}
..
// search for .xlsx (MS Excel 2010) driver
string xlsxdriver = GetODBCDriverForExtension('*.xlsx');
// search for .accdb (MS Access 2010) driver
string accdbdriver = GetODBCDriverForExtension('*.accdb');
private string GetODBCDriverForExtension(string extension)
{
using (RegistryKey reghklm = Registry.LocalMachine)
using (RegistryKey regdrivers = reghklm.OpenSubKey(@'SOFTWAREODBCODBCINST.INIODBC Drivers'))
{
if (regdrivers != null)
{
foreach (string driver in regdrivers.GetValueNames())
{
if (driver.IndexOf(extension) != -1) return driver;
}
}
}
return ';
}
..
// search for .xlsx (MS Excel 2010) driver
string xlsxdriver = GetODBCDriverForExtension('*.xlsx');
// search for .accdb (MS Access 2010) driver
string accdbdriver = GetODBCDriverForExtension('*.accdb');
If you prefer e.g. the English driver: check if the English driver is installed - otherwise use any valid driver for the file extension.
Disclaimer: The information on this page is provided 'as is' without warranty of any kind. Further, Arclab Software does not warrant, guarantee, or make any representations regarding the use, or the results of use, in terms of correctness, accuracy, reliability, currentness, or otherwise. See: License Agreement
Note
This article was originally posted to the AIMMS Tech Blog.
Some years ago, before Microsoft Office 2010, life was – in some sense – easier for developers: Office was 32-bit, period. In our days, since the release of Microsoft Office 2010, things are a bit more complicated, as users can now have a machine with a 64-bit native version of Office installed as well. This means, for instance, that a 32-bit application using an ODBC driver to connect to an Access database might not work anymore, since the 32-bit ODBC driver might not exist on a machine with a 64-bit Office installation. In such a case, even though the user has a valid Office installation on his or her machine, the application may still display an error regarding the installation or the registration of the proper drivers on the local machine.
In order to address such problems, Microsoft released a redistributable named Microsoft Access Database Engine 2010 Redistributable. This redistributable provides a 32-bit or a 64-bit version of the Microsoft Access Database Engine, which can be downloaded from the Microsoft Download Center:
So, for example, if you have a 32-bit application using a 32-bit ODBC driver on a machine with a 64-bit installation of Office 2010, you will need to install the 32-bit version of the Microsoft Access Database Engine as well.
Please note that launching the installation of a Microsoft Access Database Engine in the usual way, on a machine with an Office installation architecture different from the current one (e.g. 32-bit on 64-bit), may cause the installation to fail. To have it run properly, you need to launch it from a command line with the
/passive
argument specified:- To install the Microsoft Access Database Engine 32-bit on a machine running Office 2010 64-bit:
- To install the Microsoft Access Database Engine 64-bit on a machine running Office 2010 32-bit:
In order to use the new driver from your AIMMS project for connecting to an Access database, you need to adjust the Data Source Name (.dsn) file associated with your Access database. Typically that .dsn file contains something like:
This should be changed to look like (where the changes are highlighted):
Microsoft Access Driver Mdb Accdb Odbc Drivers For Mac Windows 7
In order to use the new driver from your AIMMS project for reading CSV files by using ODBC, you need to adjust the DSN file associated with your (sub-) folder containing the CSV files. Typically that DSN file contains something like:
In this example, Data is the subfolder of your AIMMS Project directory containing the CSV files.
For the new driver this should be changed to look like (where the changes are highlighted):
Driver= Microsoft Access Driver (*.mdb)
Please note that the above is applicable to Office 2010 as well as to Office 2013. In case of Office 2013, the installation steps above should suffice. However, when Office 2010 32-bit is natively installed and the user tries to install the 64-bit version of the Microsoft Access Database Engine, he or she might still get an error regarding the registration of the proper drivers on the local machine. Should such a situation occur, please try the following workaround:
![Mac Mac](https://i.ytimg.com/vi/Ph3MEl7-oyM/maxresdefault.jpg)
- Check the 64-bit registry key
HKEY_LOCAL_MACHINESOFTWAREMicrosoftOffice14.0CommonFilesPaths
before installing the 64-bit version of the Microsoft Access Database Engine 2010 redistributable. - If it does not contain the
mso.dll
registry value, then you will need to rename or delete the value after installing the 64-bit version of the Microsoft Access Database Engine 2010 redistributable on a system with a 32-bit version of MS Office installed. - Use the
/passive
command line parameter to install the redistributable, e.g.'C:directorypathAccessDatabaseEngine_x64.exe'/passive
- Delete or rename the
mso.dll
registry value, which contains the path to the 64-bit version ofmso.dll
(and should not be used by 32-bit MS Office versions). - Now you can start a 32-bit MS Office application without the “re-configuring” issue.
Microsoft Access Driver Mdb Accdb Odbc Drivers For Mac Free
Note that the
mso.dll
registry value will already be present if a 64-bit version of MS Office is installed. In this case the value should not be deleted or renamed.Microsoft Access Driver Mdb Accdb Odbc Drivers For Mac Download
Last Updated: September, 2020