A.M wrote: > I am asking this because I learned that DB-API in Python doesn't offer > access to cursor columns by name. The only option is access by index. I > hope that I've got it wrong!
While it's not part of the DB-API as far as I know, the MySQLdb package (and perhaps other DB access modules as well, I don't know) provides a "DictCursor" class that returns query results as a tuple of column-keyed dictionaries (hashes, already demonstrated by Brian). Jeffrey -- http://mail.python.org/mailman/listinfo/python-list