You can also simply specify a query as raw SQL:
db(('1 = 1')).select(db.mytable.ALL)
Anthony
On Friday, November 25, 2016 at 10:46:44 AM UTC-5, Anthony wrote:
>
> db.mytable.id > 0
>
> Anthony
>
> On Thursday, November 24, 2016 at 1:03:10 AM UTC-5, Jurgis Pralgauskis
> wrote:
>>
>> Hi,
>>
>> I dynamically generate queries from my search form fields/filters.
>> and then map reduce the query list...
>> But if no filter is selected, I get empty list...
>>
>> So I try to add dummy query to the beginning:
>> Query(db, db._adapter.EQ, 1, 1)
>>
>> but I get
>>
>> AttributeError: 'SQLite' object has no attribute 'EQ'
>>
>>
--
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.