sql join on

QUERY = '''
select animals.name 
from animals join diet on animals.species = diet.species
where food = 'fish';
'''

having

QUERY = '''
select species, count(*) as num 
from animals group by species
having num = 1;
'''
QUERY = '''
select species, count(*) as num 
from animals group by species
having num = 1;
'''

QUERY = '''
select diet.food, count(*) as num
from animals join diet on animals.species = diet.species
group by food
having num = 1;
'''