PostgreSQL CASE statement syntax issues
I receive a syntax error for the following: CREATE OR REPLACE FUNCTION my_function(old_num INTEGER) returns INTEGER language plpgsql AS $$ DECLARE new_num INTEGER; BEGIN CASE WHEN (old_num IN (1, 2, 3, 4)) THEN new_num = 10 WHEN (old_num IN (5,…