odbc and accessing database results by field

Robert Brewer fumanchu at amor.org
Tue Oct 28 16:57:05 EST 2003


True; but wait until you have to retrieve a date value before 1970. :)

Does it have to be odbc? If you tell us the underlying database, some
here might be able to direct you to better connectors...or at least
workarounds for odbc, specific to your database.


FuManChu

> -----Original Message-----
> From: JZ [mailto:jroznfgre at jngpugbjreXEBCXNbet.cy] 
> Sent: Tuesday, October 28, 2003 1:35 PM
> To: python-list at python.org
> Subject: Re: odbc and accessing database results by field
> 
> 
> On Tue, 28 Oct 2003 10:58:37 -0800, "Robert Brewer"
> <fumanchu at amor.org> wrote:
> 
> >My answer was incomplete, since 'description' returns a sequence (not
> >just the name). So for the line "fieldNames = c.description",
> >substitute:
> >
> >fieldNames = [eachColumn[0] for eachColumn in c.description]
> 
> Thanx. The key for solution was the "c.description" which I have never
> seen before. The only side-effect is, c.description returns changed
> case of all field names. They are all lower case :(
> 
> -- 
> JZ ICQ:6712522
> 
> -- 
> http://mail.python.org/mailman/listinfo/python-list
> 





More information about the Python-list mailing list