简体   繁体   English

ProgrammingError:运算符不存在:integer = boolean

[英]ProgrammingError: operator does not exist: integer = boolean

File "/home/bellvantage/Documents/openerp-7.0/openerp-7.0/openerp/sql_db.py", line 226, in execute
res = self._obj.execute(query, params)
ProgrammingError: operator does not exist: integer = boolean
LINE 1: ...=1,write_date=(now() at time zone 'UTC') where id IN (false)
                                                             ^
HINT:  No operator matches the given name and argument type(s). You might need to add explicit type casts.

I tried to override the write function. 我试图覆盖写入功能。 in that i need to update another model's (bpl.company.define) column also.so i used the write() method.but its give above error & need to sort it. 因为我需要更新另一个模型的(bpl.company.define)列。所以我使用了write()方法。但它给出了上面的错误并需要对它进行排序。 please advice me and explaint which parameters need to pass for the write() method (except cr,uid). 请建议我和explainint需要为write()方法传递哪些参数(cr,uid除外)。

I upload my model class here . 在这里上传我的模型类。 & view class here . 在这里查看课程。

Line number 100 in bpl.py bpl.py中的第100行

Ok its sorted friend.issue with my entered data in database.the data which is going to read is null.so thats return false and error comes like that :-) 好吧,我在数据库中输入的数据排序了friend.issue。要读取的数据是null。那就是返回false,错误就是这样:-)

“now()在时区..........”看起来很像SQL,它应该是用双引号括起来的Python字符串,而不是简单的单词。

I think in the create function in the file bpl.py, division_id you get is false and you try to browse the record which is a none type object and then trying to write to it. 我认为在文件bpl.py中的create function中,你得到的division_id为false,你试图浏览一个无类型对象的记录,然后尝试写入它。 Please check whether you a correct id for division_id. 请检查您是否为division_id的正确ID。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 编程错误:运算符不存在:整数=布尔值-Odoo v9社区 - ProgrammingError: operator does not exist: integer = boolean - Odoo v9 community django.db.utils.ProgrammingError:运算符不存在:可变字符=整数 - django.db.utils.ProgrammingError: operator does not exist: character varying = integer Django-选择对象时出错:“ ProgrammingError:运算符不存在:可变字符=整数) - Django - Error selecting objects: "ProgrammingError: operator does not exist: character varying = integer) ProgrammingError at / 关系不存在 - ProgrammingError at / relation does not exist django.db.utils.ProgrammingError:运算符不存在:字符更改日期 - django.db.utils.ProgrammingError: operator does not exist: character varying date Psycopg2“运算符不存在:整数[] =整数”错误 - Psycopg2 “operator does not exist: integer[] = integer” error PostgreSQL和金字塔:ProgrammingError:关系“记录”不存在 - PostgreSQL and Pyramid: ProgrammingError: relation “records” does not exist 编程错误“ forum_userprofile”不存在 - ProgrammingError “forum_userprofile” does not exist ProgrammingError:关系“ celery_taskmeta”不存在 - ProgrammingError: relation “celery_taskmeta” does not exist ProgrammingError:关系“用户”不存在-PostgreSQL - ProgrammingError: relation “users” does not exist - PostgreSQL
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM