trouble with import odbc

wryder at wryder at
Mon Dec 10 22:48:20 CET 2001

Anyone ever seen this error given the code after that:

 File "", line 1, in ?
   import dbi, odbc, sys
 File "", line 4, in ?
   s = odbc('postgresql/postgres/n4pk1n')
TypeError: object of type 'module' is not callable
import dbi, odbc

s = odbc('postgresql/postgres/n4pk1n')
cur = s.cursor()
cur.execute('select * from discounts')
print cur.description
for tup in cur.description:
        print tup[0], print
while 1:
        rec = cur.fetchmany(10)
        if not rec: break
        print rec

Finding it very hard to chase stuff like this down.  What the heck does that
error message mean?  Maybe some nutrinos caused two bits on my hardrive to
swap so that the module is corrupt and isn't callable?  Whatever.  Anyway,
Thanks in advance!  wryder at

 -----  Posted via NewsOne.Net: Free (anonymous) Usenet News via the Web  ----- -- Free reading and anonymous posting to 60,000+ groups
   NewsOne.Net prohibits users from posting spam.  If this or other posts
made through NewsOne.Net violate posting guidelines, email abuse at

More information about the Python-list mailing list