Is it correct sql query inside jpa repository interface method annotation?

I have a library with books, readers and reservations. I need to select all book reservations by book title. Am I doing it correctly: A book may have many reservations as well as users which are readers who borrow it. Should I refer to the string title using ?1 when using native sql query? In jpql it would be the case. And is my query correct for my task?
No description
2 Replies
JavaBot
JavaBot13mo ago
This post has been reserved for your question.
Hey @Tomasm21! Please use /close or the Close Post button above when your problem is solved. Please remember to follow the help guidelines. This post will be automatically closed after 300 minutes of inactivity.
TIP: Narrow down your issue to simple and precise questions to maximize the chance that others will reply in here.
JavaBot
JavaBot13mo ago
Post Closed
This post has been closed by <@312509109863710732> for the following reason:
I found out myself that I am doing it right. Also chatgpt conformed it.
Want results from more Discord servers?
Add your server