Alex, alex bodnaru wrote: > -----BEGIN PGP SIGNED MESSAGE----- > Hash: SHA1 > > > hello friends, > > as opposed to a table.query() that returns a list of records of that table, > with > fields accessible as record attributes, a select() statement returns a list of > tuples with the values of the fields in the virtual record. > > i'd like to access the fields by their column name or label, at least the non > calculated or labelled ones. it would suffice to be able to retrieve a list > with > the labels of the fields in the resulted tuples. > > could you point me in the right direction? > No expert, so take this with a grain of salt.
q = db.Quality.__table__.select() print q print dir(q) print q.columns q.columns is giving the column names as a list Werner --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "sqlalchemy" group. To post to this group, send email to sqlalchemy@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/sqlalchemy?hl=en -~----------~----~----~----~------~----~------~--~---