CASE
CASE WHEN cond THEN x ... ELSE y END is an expression that picks a value per row.
task
Label products cheap (<2000), mid (<10000), premium. Return product_id and the label.
Run a query to see rows here.
Run EXPLAIN on the statement under the cursor: Plan tab, button Explain.
No tables yet.
CASE WHEN cond THEN x ... ELSE y END is an expression that picks a value per row.
Label products cheap (<2000), mid (<10000), premium. Return product_id and the label.