I have a table with empty list:reference fields and db admin does not
have a problem with it.
Running 1.91.6 .


On Jan 28, 10:12 am, LightOfMooN <vladsale...@yandex.ru> wrote:
> It's a problem, that if i have empty list:reference, the standard
> database administration don't work because of wrong query:
>
> Traceback (most recent call last):
>   File "/home/www-data/web2py/gluon/restricted.py", line 188, in
> restricted
>     exec ccode in environment
>   File "/home/www-data/web2py/applications/funportal/views/
> appadmin.html", line 191, in <module>
>     <p>
>   File "/home/www-data/web2py/gluon/sqlhtml.py", line 1349, in
> __init__
>     r = field.represent(r)
>   File "/home/www-data/web2py/gluon/dal.py", line 3113, in
> list_ref_repr
>     refs = r._db(r.id.belongs(ids)).select(r.id)
>   File "/home/www-data/web2py/gluon/dal.py", line 4507, in select
>     return self.db._adapter.select(self.query,fields,attributes)
>   File "/home/www-data/web2py/gluon/dal.py", line 1003, in select
>     rows = response(sql)
>   File "/home/www-data/web2py/gluon/dal.py", line 994, in response
>     self.execute(sql)
>   File "/home/www-data/web2py/gluon/dal.py", line 1067, in execute
>     return self.log_execute(*a, **b)
>   File "/home/www-data/web2py/gluon/dal.py", line 1064, in log_execute
>     return self.cursor.execute(*a,**b)
> ProgrammingError: syntax error at or near ")"
> LINE 1: SELECT  tag.id FROM tag WHERE (tag.id IN ());

Reply via email to