Please help me to write the following SQL query using DAL:
SELECT indicator.*, v.date, v.value FROM indicator
LEFT JOIN (
SELECT value.value, _.indicator, date
FROM (SELECT indicator, min(client_date) AS date FROM value WHERE
created_by = 1 GROUP BY indicator) _
LEFT JOIN
, cache, etc) and use
db.tablename.name_of_the_field.default = your previously saved value
On Monday, May 20, 2013 6:04:27 AM UTC+2, Denis Rykov wrote:
I have SELECT item in my form. How I can save state of this item after
form submission?
It looks like I should use selected attribute, but I
.
options = [OPTION(text, _value=value, _selected=True)]
On Monday, May 20, 2013 7:05:11 PM UTC+2, Denis Rykov wrote:
Thanks for response. But I build form manually, not from database table.
What I have to do in this case?
On Monday, May 20, 2013 1:52:06 PM UTC+7, Niphlod wrote:
when you
I have field defenition:
Field('company', 'reference company', notnull=True, label='Company')
and I want to add ondelete restriction:
Field('company', 'reference company', notnull=True, label='Company',
ondelete='NO ACTION')
But web2py did not alter database. Is it expected behavior?
I have SELECT item in my form. How I can save state of this item after form
submission?
It looks like I should use selected attribute, but I can't find any
examples how I can do it with web2py.
--
---
You received this message because you are subscribed to the Google Groups
web2py-users
Trying to install web2py in virtualenv on Ubuntu but when I run w2p_run I
get an error RuntimeError: Cannot determine web2py version.
--
---
You received this message because you are subscribed to the Google Groups
web2py-users group.
To unsubscribe from this group and stop receiving emails
I use the following Field definition:
Field('admin_unit', required=True, label='Region'),
But when I create new row through smartgrid interface and leave this field
empty - validation error not appears and record creates in database. If see
table in database you can see that 'admin_unit' field
I would like make one to one tables relation. For example:
db.define_table('contract',
Field('num', unique=True, notnull=True'),
...
db.define_table('student',
Field('contract', db.contract, unique=True, notnull=True,
label='Договор'),
But unique and notnull options doesnt reflects
8 matches
Mail list logo