我正在使用skife来帮助我处理数据库查询。我有下面的查询和方法。Postgres查询必须是布尔类型
@SqlQuery("select * from profile where profile_id >= :from and profile_id < :to")
List<Profile> findAllInRange(@Bind("from")int from, @Bind("to")int to);
我收到以下错误
org.postgresql.util.PSQLException: ERROR: argument of AND must be type boolean, not type bigint
但如果我执行这个查询
select * from profile where profile_id >= 1 and profile_id < 50
我RDBMS成功返回结果。
我错过了什么?
解析它放置在
\\
操作<
前一个布尔 – ja08prat@ ja08prat是什么意思呢?对不起,我很抱歉。 – MaxPower
在'<'运营商 – MinMiguelM