Hi, Good advice. I configured the ODBC data sources as advised and I am now able to query my database files.
Thanks, John. -----Original Message----- From: Lloyd Kvam [mailto:[EMAIL PROTECTED] Sent: 15 April 2006 16:04 To: [EMAIL PROTECTED] Cc: Kent Johnson; Tutor Python Subject: Re: [Tutor] odbc On Sat, 2006-04-15 at 16:03 +0100, John Corry wrote: > Kent, > > I am not sure what you mean. I am feeling about in the dark on this > subject. > > Do you have an example? You should have a Control Panel Application for configuring ODBC data sources. The program using an ODBC driver is separated from the actual file. Instead the DSN name is matched against a registry entry to find the actual file or database. So you won't get anywhere until you get the ODBC registry stuff straight. That's also why the unit tests fail. (This is from a Linux guy, so the exact details could be off a little bit, but hopefully it points you in the right direction.) > Among my visual foxpro database files I have a file > called tng.dbc. When I acces the database files through excel, I select the > tng.dbc before I can see the fields in the databases. Is this what I need > to log onto with python first before I access the database file? > > Regards, > > John. > > > -----Original Message----- > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] > Behalf Of Kent Johnson > Sent: 15 April 2006 15:40 > Cc: tutor@python.org > Subject: Re: [Tutor] odbc > > > John CORRY wrote: > > I have just run the test package within mxODBC. I get the following > result. > > OperationalError: ('IM002', 0, '[Microsoft][ODBC Driver Manager] Data > > source name not found and no default driver specified', 6044) > > > > It gives me the same error that I am experiencing when I run my code. > > Does this mean that I have not installed something that I need or have > > not installed something properly. > > Have you configured an ODBC data source for the database you are trying > to access? I don't remember how to do this but I know it was a necessary > step for accessing MS-Access databases from ODBC. > > Kent > > _______________________________________________ > Tutor maillist - Tutor@python.org > http://mail.python.org/mailman/listinfo/tutor > > _______________________________________________ > Tutor maillist - Tutor@python.org > http://mail.python.org/mailman/listinfo/tutor -- Lloyd Kvam Venix Corp. 1 Court Street, Suite 378 Lebanon, NH 03766-1358 voice: 603-653-8139 fax: 320-210-3409 _______________________________________________ Tutor maillist - Tutor@python.org http://mail.python.org/mailman/listinfo/tutor