the code not respond, does not give input | Sololearn: Learn to code for FREE!
Novo curso! Todo programador deveria aprender IA generativa!
Experimente uma aula grƔtis
+ 3

the code not respond, does not give input

code practice Online Bookstore SELECT * FROM books WHERE author = 'Fiction'

1st Nov 2023, 8:59 AM
AMIR H R A<ćƒ¾(@^ā–½^@)惎 >LION šŸ’Ŗ
AMIR  H  R A<ćƒ¾(@^ā–½^@)惎 >LION šŸ’Ŗ - avatar
21 Respostas
+ 6
Read the requirement of that practice code carefully.It is clearly mentioned to extract books with 'Fiction' genre not 'Fiction' author. So why you have used `author`. Replace it with `genre` So your code should be- SELECT * FROM books WHERE genre = 'Fiction';
1st Nov 2023, 9:53 AM
Gulshan Mahawar
Gulshan Mahawar - avatar
+ 4
it is true that I had not paid attention to this
1st Nov 2023, 10:00 AM
AMIR H R A<ćƒ¾(@^ā–½^@)惎 >LION šŸ’Ŗ
AMIR  H  R A<ćƒ¾(@^ā–½^@)惎 >LION šŸ’Ŗ - avatar
+ 3
author = 'Fiction' ???
1st Nov 2023, 9:08 AM
Wong Hei Ming
Wong Hei Ming - avatar
1st Nov 2023, 9:10 AM
Ausgrindtube
Ausgrindtube - avatar
+ 3
Doesn't answer
2nd Nov 2023, 8:30 PM
AMIR H R A<ćƒ¾(@^ā–½^@)惎 >LION šŸ’Ŗ
AMIR  H  R A<ćƒ¾(@^ā–½^@)惎 >LION šŸ’Ŗ - avatar
+ 3
write the query to select the dessert name and place from the desserts table where the dessert name contains the word 'Chocolate' this practice
2nd Nov 2023, 8:48 PM
AMIR H R A<ćƒ¾(@^ā–½^@)惎 >LION šŸ’Ŗ
AMIR  H  R A<ćƒ¾(@^ā–½^@)惎 >LION šŸ’Ŗ - avatar
+ 3
thanks Koli that's right I forgot and all guys
3rd Nov 2023, 6:36 AM
AMIR H R A<ćƒ¾(@^ā–½^@)惎 >LION šŸ’Ŗ
AMIR  H  R A<ćƒ¾(@^ā–½^@)惎 >LION šŸ’Ŗ - avatar
+ 2
write a query to select all fields from the books table but only retrieve the books that belong to the 'Fiction' genre Online Bookstore practice sql ...
1st Nov 2023, 9:25 AM
AMIR H R A<ćƒ¾(@^ā–½^@)惎 >LION šŸ’Ŗ
AMIR  H  R A<ćƒ¾(@^ā–½^@)惎 >LION šŸ’Ŗ - avatar
+ 2
AMIR H R A<ćƒ¾(@^ā–½^@)惎 >LION šŸ’Ŗ Didn't you just write the hint? <books that belong to the 'Fiction' genre>
1st Nov 2023, 9:27 AM
Wong Hei Ming
Wong Hei Ming - avatar
+ 2
yes
1st Nov 2023, 9:49 AM
AMIR H R A<ćƒ¾(@^ā–½^@)惎 >LION šŸ’Ŗ
AMIR  H  R A<ćƒ¾(@^ā–½^@)惎 >LION šŸ’Ŗ - avatar
+ 2
the code not respond does not give input ? SELECT * FROM desserts WHERE name LIKE '%Chocolate'; the project of sql Chocolate code
2nd Nov 2023, 6:16 PM
AMIR H R A<ćƒ¾(@^ā–½^@)惎 >LION šŸ’Ŗ
AMIR  H  R A<ćƒ¾(@^ā–½^@)惎 >LION šŸ’Ŗ - avatar
+ 2
doesn't answer
2nd Nov 2023, 9:00 PM
AMIR H R A<ćƒ¾(@^ā–½^@)惎 >LION šŸ’Ŗ
AMIR  H  R A<ćƒ¾(@^ā–½^@)惎 >LION šŸ’Ŗ - avatar
+ 2
Try this one bro- SELECT name,price FROM desserts WHERE name LIKE '%chocolate%'; You just forgot to put `%` at the end of the chocolate no need of any uppercase or lowercase and the practice code is asking for extract name and price not all thing!
3rd Nov 2023, 12:12 AM
Gulshan Mahawar
Gulshan Mahawar - avatar
+ 2
AMIR H R A<ćƒ¾(@^ā–½^@)惎 >LION šŸ’Ŗ If you have a new question, pleaes post in a new post. Prathish K K I'm not sure if you reached this particular exercise, you suggestion looks logical on the surface but doesn't match the table in question. Please don't spam with educated guess.
3rd Nov 2023, 1:14 AM
Wong Hei Ming
Wong Hei Ming - avatar
+ 2
thanks Koli it is true and all guys
3rd Nov 2023, 3:07 PM
AMIR H R A<ćƒ¾(@^ā–½^@)惎 >LION šŸ’Ŗ
AMIR  H  R A<ćƒ¾(@^ā–½^@)惎 >LION šŸ’Ŗ - avatar
+ 1
Check the table name first
2nd Nov 2023, 8:38 PM
Prathish K K
Prathish K K - avatar
0
Add semi-colon " ; "at the end bro
2nd Nov 2023, 8:22 PM
Prathish K K
Prathish K K - avatar
0
To check all the tables use SHOW TABLES; The view the whole table once SELECT * FROM <table_name>; And then check the corresponding column name and the value you used in the query before
2nd Nov 2023, 8:40 PM
Prathish K K
Prathish K K - avatar
0
Select dessert_name from desserts where dessert_name = 'Chocolate';
2nd Nov 2023, 8:50 PM
Prathish K K
Prathish K K - avatar
0
dessert_name is the column name
2nd Nov 2023, 8:50 PM
Prathish K K
Prathish K K - avatar