Each task asks for a label that is not in the table. Build it with CASE.
-
Each customer's
name, thenmemberfor members andguestfor the others. -
Think before you run it: what does this return for a product with stock 0?
textCASE WHEN stock < 20 THEN 'low' WHEN stock = 0 THEN 'out' ELSE 'ok' END -
Each product's
name,stock, then a label:outwhen the stock is 0,lowwhen it is below 20,okfor the others. -
Each order's
id,status, thenopenfor pending and shipped orders andclosedfor the others.