我正在使用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