Oh, yeah, that's right. Sorry about that.
I suspect the problem could indeed be with a query in a virtual field but I
don't know enough about it to say for sure.
Another option might be to implement it as just a regular function.
On Monday 15 August 2011 19:47:09 pbreit wrote:
> I think you might have to dereference r. Something like r[0].odo since
> queries return a set even if there's only one element.
From my tests, the .first() in the query:
> r = db(q).select(db.trip.odo, orderby=o, limitby=(0,1)).first()
seems to r
I think you might have to dereference r. Something like r[0].odo since queries
return a set even if there's only one element.
Hi All,
I'm new to web2py and am trying to get my mind around how virtual fields work.
Given the following table:
db.define_table("trip",
Field("date", "date"),
Field("odo", "integer")
)
which represents a trip taken by car on a specific date an
4 matches
Mail list logo