Massimo , can you check is that a bug of web2py?

I got BadValueError , using 1.98.2 version on GAE

Controller is very simple :

def get_items():
        response.generic_patterns = ['json']
        query=(db.item.id>=0)
        return response.json(db(query).select(db.item.id,db.item.name))

Thats it.

Regards

Phyo.
On 10/23/11, Phyo Arkar <[email protected]> wrote:
> any idea?
>
> On 10/23/11, Phyo Arkar <[email protected]> wrote:
>> I am using 1.98.2
>>
>> here is my model :
>>
>> db.define_table("item",
>>       SQLField("name", "text", length=512, notnull=True, default=None),
>>       SQLField("base_price", "integer", notnull=True, default=None),
>>       SQLField("price", "integer", notnull=True, default=None)
>>       )
>>
>>
>> """
>> Table definition
>> """
>> from datetime import date
>> import time
>>
>> db.define_table("sale",
>>       SQLField("id_items", db.item),
>>       SQLField("date", "date", notnull=True, default=date.today()),
>>       SQLField("sale_time", "datetime", notnull=True,
>> default=request.now),
>>       SQLField("total_items", "integer", notnull=True, default=None),
>>       SQLField("description", "text", notnull=False, default=None))
>>
>> On Sun, Oct 23, 2011 at 5:43 AM, howesc <[email protected]> wrote:
>>
>>> what's the model?
>>>
>>> what version of web2py are you using?
>>>
>>
>

Reply via email to