[Chicago] How to get table names from ODBC?

Tim Ottinger tottinge at gmail.com
Fri Aug 3 18:50:18 CEST 2007


Isn't that database-dependent and not connection-mode dependent?
Every database has system tables, and they don't have standardize name and
schema across database vendors.
If there is a general way, i do not know it.



On 8/3/07, Lukasz Szybalski <szybalski at gmail.com> wrote:
>
> Hello,
> I am using python win32 extentions.
>
> I get connected via odbc to a database files that are sitting in the
> folder.
>
> import dbi,odbc
> db=odbc.odbc('dbfiles')
> cursor=db.cursor()
> cursor.execute('select * from tableabcd')
> print  cursor.description
>
> This way I am able to find column names.
> How do i find a available table names?  I have 20 tables available to
> me. How do I list their names??
>
> Lucas
> _______________________________________________
> Chicago mailing list
> Chicago at python.org
> http://mail.python.org/mailman/listinfo/chicago
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.python.org/pipermail/chicago/attachments/20070803/2082ee5c/attachment.htm 


More information about the Chicago mailing list