0

I have repository method:

@Query(value = "select t from Transaction t " +
        "where t.bankAccountId in (:bankAccountIds) " +
        "and t.tradeTime is not null " +
        "and t.ccy is not null " +
        "and t.net is not null " +
        "and t.tradeTime >= :startDate and t.tradeTime <= :endDate " +
        "and t.status = :status")
List<Transaction> findAllByBankAccountIdInAndTradeTimeBetween(@Param("bankAccountIds") Iterable<UUID> bankAccountIds,
                                                              @Param("status") TransactionStatus status,
                                                              @Param("startDate") LocalDateTime startDate,
                                                              @Param("endDate") LocalDateTime endDate);

But when I tried to use this code I have exception:

Caused by: org.postgresql.util.PSQLException: ERROR: syntax error at or near ")"

How to fix it?

Mark Rotteveel
  • 100,966
  • 191
  • 140
  • 197
Krazim00da
  • 307
  • 1
  • 5
  • 14

1 Answers1

0

I think you don't need the brackets (:bankAccountIds)

hecko84
  • 1,224
  • 1
  • 16
  • 29