On 6/18/07, Bill Denney <[EMAIL PROTECTED]> wrote: > Matt Richardson wrote: > > Sorry for what is probably a painfully obvious question, but I can't > > figure out why this: > > > > def results(): > > row = AttendanceRecord.select() > > for i in row: > > print i > > > > produces this: > > > > <AttendanceRecord 1L sid='831649232' timeIn='datetime.datetime...)'> > > <AttendanceRecord 2L sid='831649232' timeIn='datetime.datetime...)'> > > > > Specifically, why is each row truncated? I've only been at sqlobject > > for a couple of days and I like it a lot more than mysqldb, but this > > is driving me a little nutty. > > > It just shows summary data. If you want to see everything, you can do > something like: > > def results(): > row = AttendanceRecord.select() > for i in row: > print "%d %s %s" % (i.id, i.sid, i.timeIn) > > There may be a way to make it print everything as well, but I don't know > that. > > Bill >
I think I might go through the code and see what's what. My guess was, as you said, select() was returning a summary, indicated by the ... just before the last ). The problem I was running in to was that this is not what is shown in the sqlobject examples at sqlobject.org. Maybe my result sets were longer than the examples and that's where I got bit. Thanks for the example, I think that might do the trick. -- Matt ------------------------------------------------------------------------- This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ _______________________________________________ sqlobject-discuss mailing list sqlobject-discuss@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/sqlobject-discuss