PostgreSQL - PL/pgSQL Fundamentals
What will be the output of this PL/pgSQL block?
DECLARE
arr integer[] := ARRAY[1, 2, 3];
result text := '';
BEGIN
FOREACH val IN ARRAY arr LOOP
result := result || val || ',';
END LOOP;
RAISE NOTICE '%', result;
END;