select * from recipe;
select baseflavor, cartonsordered from recipe;
select baseflavor, co as cartonsordered from recipe;
select name from recipe where baseflavor='Chocolate';
select * from flavor, recipe;
select * from flavor, recipe where flavor.name = recipe.baseflavor;
select recipe.name, cpc as costpercarton from flavor, recipe where flavor.name = recipe.baseflavor;
select recipe.name, cpc as costpercarton from flavor join recipe on flavor.name = recipe.baseflavor;
select * from recipe natural join flavor;
select * from recipe join recipe_mixins on name=recipe_name;
select * from recipe left join recipe_mixins on name=recipe_name;
select * from recipe outer join recipe_mixins on name=recipe_name;
select name, count(*) from recipe group by name;
select baseflavor, count(*) from recipe group by baseflavor;
select baseflavor, sum(co) from recipe group by baseflavor;
select baseflavor, count(*), sum(co) from recipe group by baseflavor;
select baseflavor, min(co) from recipe group by baseflavor;
select baseflavor, avg(co) from recipe group by baseflavor;
select baseflavor, avg(co) from recipe where avg(co) > 200 group by baseflavor;
select baseflavor, avg(co) from recipe group by baseflavor having avg(co) > 200;
select baseflavor, avg(co) from recipe group by baseflavor where baseflavor <> 'Vanilla' having avg(co) > 200;
select baseflavor, avg(co) from recipe where baseflavor <> 'Vanilla' group by baseflavor having avg(co) > 200;
select baseflavor, avg(co) from recipe group by baseflavor order by avg(co);
select baseflavor, avg(co) from recipe group by baseflavor order by baseflavor;
select baseflavor, avg(co) from recipe group by baseflavor order by baseflavor desc;
select baseflavor, avg(co) from recipe group by baseflavor order by avg(co) desc;
select * from recipe order by baseflavor, co;
select * from recipe order by baseflavor desc, co;
select * from recipe order by baseflavor desc, co desc;
select * from recipe limit 3;
select * from recipe limit 3 offset 3;
select * from recipe limit 3 offset 6;
