We would like to help animals at the Ron Animal Shelter in Root (LU) that are up for adoption (tierschutz-luzern.ch) in our database.
Your tables: gehege, tierart, tier.
tierart (columns: name, herkunft)
Hund, Weltweit domestiziert Katze, Weltweit domestiziert Kaninchen, Europa
gehege (columns: name, standort, flaeche)
Hundeaussenbereich 1, Garten, 45.50 Kleintierraum, Innenbereich, 20.00 Katzenzimmer, Innenbereich, 15.00
tier (Columns: name, geburtsdatum, geschlecht, gehege_id, art_id)
('Zuki', '2024-04-01', 'w', 2, 3), ('Sokka', '2024-04-01', 'm', 2, 3), ('Mila', '2019-09-03', 'w', 3, 2), ('Bäry', '2022-01-20', 'm', 1, 1), ('Luigi', '2025-09-01', 'm', 1, 1), ('Fred', '2025-11-01', 'm', 1, 1);
Try to create an animal without a name. Read the error message.
Filter by name, e.g. ''WHERE name = 'Mila' ''. For both animals at the same time, you could use, for example: ''WHERE name = 'Luigi' OR name = 'Fred' ''. Use SELECT beforehand to check how many rows are affected.