I have a parameter of integers. I need to write a custom Spring JPA query where the equivalent SQL would be . . . AND x.propertyStatusId IN (1,2)
. . .
I see in the Spring Data JPA documentation the keyword is "IN" as in "findByAgeIn(Collection<Age> ages)"
that translates to "where x.age in ?1" But I get an error. I am using an arrayList of integers.
ArrayList<Integer> propertyStatusId = new ArrayList<Integer>();
propertyStatusId.add(1);
propertyStatusId.add(2);
findByPropertyOwnerIdAndIn(propertyStatusId)AndListingDateGreaterThanEqual(user.getId(),propertyStatusId, ListingDate, pageable);