postgresql_16:7.1.74.4 Examples
PostgreSQL 16 > Reference > SQL Commands > CREATE PROCEDURE > Examples
CREATE PROCEDURE insert_data(a integer, b integer) LANGUAGE SQL AS $$ INSERT INTO tbl VALUES (a); INSERT INTO tbl VALUES (b); $$; or CREATE PROCEDURE insert_data(a integer, b integer) LANGUAGE SQL BEGIN ATOMIC INSERT INTO tbl VALUES (a); INSERT INTO tbl VALUES (b); END; and call like this: CALL insert_data(1, 2);