+ 2

Zoo project

Answer in SQL INSERT INTO Animals (name, type, country_id) VALUES ('Slim', 'Giraffe', 1); SELECT animals.name, animals.type, countries.country FROM animals, countries WHERE animals.country_id=countries.id order by animals.country_id desc

24th Apr 2021, 3:22 PM
GANGINENI SIVA SAI
GANGINENI SIVA SAI - avatar
3 Respostas
0
Output depends entirely on the contents of the "countries" table.
24th Apr 2021, 3:29 PM
Abhishek Tandon
Abhishek Tandon - avatar
0
Yeah bruh.....
24th Apr 2021, 3:30 PM
GANGINENI SIVA SAI
GANGINENI SIVA SAI - avatar
0
INSERT INTO animals (name, type, country_id) VALUES ('Slim', 'Giraffe', 1); SELECT animals.name, animals.type, countries.country FROM animals INNER JOIN countries ON animals.country_id=countries.id ORDER BY animals.country_id DESC Just needed changing from: WHERE animals.country_id=countries.id to: ON animals.country_id=countries.id
10th Jun 2022, 12:21 PM
Joseph Symes
Joseph Symes - avatar