Hello I am working with xlwt and trying to export a table of mine into a .xls file. This table contains some foreign keys, and they are being exported as the id of the other table rathan than the 'name' field, which is what I want to display. I define the foreign key fields in the table like this:
Field('owner', db.person, requires = IS_EMPTY_OR(IS_IN_DB(db, db.person, '%(name)s')), represent=lambda id, row: db.person(id).name if id else ' '), Thanks! --