On Sunday, March 27, 2016 at 10:31:37 PM UTC-4, Alfonso Serra wrote: > > Sorted out with: > rows = db(db.mytable).select(*[db.mytable[f] for f in > db.mytable.fields[0:5]) >
Yes, .select() takes field objects, not just field names. Iterating over the table object itself yields its field objects, so slightly more simply, you could do: [f for f in db.mytable][0:5] Anthony -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py/issues/list (Report Issues) --- You received this message because you are subscribed to the Google Groups "web2py-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.

