I am using Python 2.7.8 32-bit to call MS Access 2007.
Below is the code I use:
import sys
import pypyodbc
import os
import pyodbc
conn = pyodbc.connect(r"DRIVER={Microsoft Access Driver (*.mdb, *.accdb)}; Dbq=D:\Access\Geocoding.accdb;")
cnxn = pyodbc.connect(conn)
I get the error message:
Traceback (most recent call last): File "D:\Access\get_Access.py", line 13, in conn = pyodbc.connect(r"DRIVER={Microsoft Access Driver (*.mdb, *.accdb)}; Dbq=D:\Access\Geocoding.accdb;") Error: ('IM002', '[IM002] [Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified (0) (SQLDriverConnect)')
I searched online for a while and couldn't find anything wrong with the code.