#289 Finding Authors with a Single Book Genre
The following tables are given:
Table genre
genre_id | name_genre
---------|-------------
1 | Novel
2 | Poetry
3 | Adventure
Table author
author_id | name_author
----------|------------------
1 | Bulgakov M.A.
2 | Dostoevsky F.M.
3 | Yesenin S.A.
4 | Pasternak B.L.
5 | Lermontov M.Yu.
Table book
book_id | title | author_id | genre_id | price | amount
--------|------------------------|-----------|----------|--------|--------
1 | The Master and Margarita | 1 | 1 | 670.99 | 3
2 | The White Guard | 1 | 2 | 540.50 | 5
3 | The Idiot | 2 | 1 | 460.00 | 10
4 | The Brothers Karamazov | 2 | 1 | 799.01 | 3
5 | The Gambler | 2 | 1 | 480.50 | 10
6 | Poems | 3 | 2 | 650.00 | 15
7 | The Black Man | 3 | 2 | 570.20 | 6
8 | Lyrics | 4 | 2 | 518.99 | 2
Display in alphabetical order all authors who write in only one genre.
Question review
Sign in to start the dialogue
The mentor keeps the context of the current question and your previous messages.
Sign in
Available with Premium
This is just one of the solutions available with Premium. And more:
- 250+ advanced lectures
- 1300+ practice exercises
- 500+ solutions to problems from real interviews
- Personalized Java Hub certificates
- Expanded access to the AI mentor