3. queryΒΆ

Last page update: November 23, 2011

TODO

In a query you can refer itself to the primary key of a database table with the following syntax:

where='$pkey=:pkey'

Example:

>>> db.table('location.province').query(where='$pkey=:pkey',pkey='MI',addPkeyColumn=False).fetch()
[initials=MI,region=LOM,name=Milan,istat_code=013,order=22,total_order=None,valid_vat=None]

Previous topic

2. relation method - attributes explanation

Next topic

4. sql attributes

This Page