[web2py] Re: Some help with computed field in a query

2016-04-05 Thread Henk huisman
Sometimes it's simple, just use the function *CONCAT('../rentals_manage/',rentals.id)* this is at least valid for the MySQl database I am using. So if I understand well If you are using the db.executesql statement the SQL you use must be specific for the database in the back? -- Resources: -

[web2py] Re: Some help with computed field in a query

2016-04-06 Thread 'DenesL' via web2py-users
Maybe you could use a virtual field and not a computed one: db.rentals.urlid = Field.Virtual( 'urlid', lambda r: URL('rentals_manage', args=r.id) ) then after rows = db(db.rentals...).select(...) the rows will contain an urlid field. http://web2py.com/books/default/chapter/29/06/the-database-ab