1、创建
CREATE OR REPLACE FUNCTION insert_kettleout(c1 BIGINT,c2 BIGINT) RETURNS BOOLEAN AS $BODY$ DECLARE result BOOLEAN := true; BEGIN INSERT INTO kettleout VALUES(c1,c2); return result; END; $BODY$ LANGUAGE plpgsql VOLATILE SECURITY DEFINER COST 100;2、调用
SELECT insert_kettleout(1,2)