Issue
If I have a query like this,
SELECT * FROM COMPANIES WHERE COMPANY_ADDRESS IN ('Texas', 'California');
How can I convert this into a spring method name query instead of using @Query
?
Solution
The query method for your case would be:
List<Company> findAllByCompanyAddressIn(List<String> addresses);
If the COMPANY_ADDRESS
column corresponds to companyAddress
entity field.
Answered By - birca123
Answer Checked By - Marilyn (JavaFixing Volunteer)