A sql lab filled with pokemon data

12345678910111213141516171819202122232425
  1. //What are all the types of pokemon that a pokemon can have?
  2. SELECT name
  3. FROM pokemon.types;
  4. //What is the name of the pokemon with id 45? Eevee
  5. SELECT name, id
  6. FROM pokemon.pokemons
  7. WHERE id = 45;
  8. //How many pokemon are there? 656
  9. SELECT id, name
  10. FROM pokemon.pokemons
  11. ORDER BY id DESC;
  12. //How many types are there? 18
  13. SELECT id, name
  14. FROM pokemon.types
  15. ORDER BY id DESC;
  16. How many pokemon have a secondary type? 316
  17. SELECT name, secondary_type
  18. FROM pokemon.pokemons
  19. WHERE secondary_type IS NOT NULL;