SQLize Online / PHPize Online  /  SQLtest Online

A A A
Share      Blog   Popular
Copy Format Clear
CREATE TABLE test_original_name AS SELECT g.id FROM generate_series(1, 100, 1) AS g(id); CREATE TABLE data_from_test_original_name(id numeric); --67273 -- SELECT 'test_original_name'::regclass::oid; CREATE OR REPLACE FUNCTION fill_table_from_other_table_fn() RETURNS void LANGUAGE sql -- SECURITY DEFINER AS $function$ BEGIN INSERT INTO data_from_test_original_name(id) SELECT id FROM test_original_name; END; $function$; SELECT fill_table_from_other_table_fn(); SELECT * FROM data_from_test_original_name;

Stuck with a problem? Got Error? Ask ChatGPT!

Copy Clear