I have a "Books" table that looks like this:
I'm trying to make a Spring Boot application that lists all these books but you can filter them by category. To do this, I want to display a list of each category so the user can click on the category they want.
What is a better way to get a list of this category? For example, in the case of the picture above, I want to display a list like this:
You can view
@Query annotation @lemon provided the solution
You can also check this