Created
March 8, 2018 20:49
-
-
Save jasonmp85/a44f17b32334621235eac6a01f497f99 to your computer and use it in GitHub Desktop.
Repro steps for citusdata/citus#2009
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
CREATE TABLE dist (id integer); | |
CREATE TABLE ref (id integer); | |
SELECT create_distributed_table('dist', 'id'); | |
SELECT create_reference_table('ref'); | |
CREATE FUNCTION dist_func() | |
RETURNS void LANGUAGE plpgsql AS $$ | |
BEGIN | |
EXECUTE 'SELECT id, $1 FROM dist' USING 1; | |
END; $$; | |
CREATE FUNCTION ref_func() | |
RETURNS void LANGUAGE plpgsql AS $$ | |
BEGIN | |
EXECUTE 'SELECT id, $1 FROM ref' USING 1; | |
END; $$; | |
SELECT dist_func(); | |
SELECT ref_func(); | |
SET auto_explain.log_min_duration TO 0; | |
SET auto_explain.log_nested_statements TO on; | |
SELECT dist_func(); | |
SELECT ref_func(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment