Spring CrudRepository findByInventoryIds(List inventoryIdList) – equivalent to IN clause

In Spring CrudRepository, do we have support for “IN clause” for a field? ie something similar to the following?

 findByInventoryIds(List<Long> inventoryIdList) 

If such support is not available, what elegant options can be considered? Firing queries for each id may not be optimal.

3 Answers
3

Leave a Comment