--
--


SET transaction_timeout = 0;
SELECT pg_catalog.set_config('search_path', '', false);

--
-- Name: fkpart3; Type: SCHEMA; Schema: -; Owner: ashutoshpg
--

CREATE SCHEMA fkpart3;


ALTER SCHEMA fkpart3 OWNER TO ashutoshpg;

--
-- Name: fkpart4; Type: SCHEMA; Schema: -; Owner: ashutoshpg
--

CREATE SCHEMA fkpart4;


ALTER SCHEMA fkpart4 OWNER TO ashutoshpg;

--
-- Name: fkpart5; Type: SCHEMA; Schema: -; Owner: ashutoshpg
--

CREATE SCHEMA fkpart5;


ALTER SCHEMA fkpart5 OWNER TO ashutoshpg;

--
-- Name: fkpart6; Type: SCHEMA; Schema: -; Owner: ashutoshpg
--

CREATE SCHEMA fkpart6;


ALTER SCHEMA fkpart6 OWNER TO ashutoshpg;

--
-- Name: generated_stored_tests; Type: SCHEMA; Schema: -; Owner: ashutoshpg
--

CREATE SCHEMA generated_stored_tests;


ALTER SCHEMA generated_stored_tests OWNER TO ashutoshpg;

--
-- Name: mvtest_mvschema; Type: SCHEMA; Schema: -; Owner: ashutoshpg
--

CREATE SCHEMA mvtest_mvschema;


ALTER SCHEMA mvtest_mvschema OWNER TO ashutoshpg;

--
-- Name: regress_indexing; Type: SCHEMA; Schema: -; Owner: ashutoshpg
--

CREATE SCHEMA regress_indexing;


ALTER SCHEMA regress_indexing OWNER TO ashutoshpg;

--
-- Name: regress_rls_schema; Type: SCHEMA; Schema: -; Owner: ashutoshpg
--

CREATE SCHEMA regress_rls_schema;


ALTER SCHEMA regress_rls_schema OWNER TO ashutoshpg;

--
-- Name: regress_schema_2; Type: SCHEMA; Schema: -; Owner: ashutoshpg
--

CREATE SCHEMA regress_schema_2;


ALTER SCHEMA regress_schema_2 OWNER TO ashutoshpg;

--
-- Name: testxmlschema; Type: SCHEMA; Schema: -; Owner: ashutoshpg
--

CREATE SCHEMA testxmlschema;


ALTER SCHEMA testxmlschema OWNER TO ashutoshpg;

--
-- Name: coll_icu_upgrade; Type: COLLATION; Schema: public; Owner: ashutoshpg
--

CREATE COLLATION public.coll_icu_upgrade (provider = icu, locale = 'und');


ALTER COLLATION public.coll_icu_upgrade OWNER TO ashutoshpg;

--
-- Name: regress_pg_c_utf8; Type: COLLATION; Schema: public; Owner: ashutoshpg
--

CREATE COLLATION public.regress_pg_c_utf8 (provider = builtin, locale = 'C.UTF-8');


ALTER COLLATION public.regress_pg_c_utf8 OWNER TO ashutoshpg;

--
-- Name: TRANSFORM FOR integer LANGUAGE sql; Type: TRANSFORM; Schema: -; Owner: -
--

CREATE TRANSFORM FOR integer LANGUAGE sql (FROM SQL WITH FUNCTION pg_catalog.prsd_lextype(internal), TO SQL WITH FUNCTION pg_catalog.int4recv(internal));


--
-- Name: gtestdomain1; Type: DOMAIN; Schema: generated_stored_tests; Owner: ashutoshpg
--

CREATE DOMAIN generated_stored_tests.gtestdomain1 AS integer
	CONSTRAINT gtestdomain1_check CHECK ((VALUE < 10));


ALTER DOMAIN generated_stored_tests.gtestdomain1 OWNER TO ashutoshpg;

--
-- Name: aggtype; Type: TYPE; Schema: public; Owner: ashutoshpg
--

CREATE TYPE public.aggtype AS (
	a integer,
	b integer,
	c text
);


ALTER TYPE public.aggtype OWNER TO ashutoshpg;

--
-- Name: arrayrange; Type: TYPE; Schema: public; Owner: ashutoshpg
--

CREATE TYPE public.arrayrange AS RANGE (
    subtype = integer[],
    multirange_type_name = public.arraymultirange
);


ALTER TYPE public.arrayrange OWNER TO ashutoshpg;

--
-- Name: cantcompare; Type: TYPE; Schema: public; Owner: ashutoshpg
--

CREATE TYPE public.cantcompare AS (
	p point,
	r double precision
);


ALTER TYPE public.cantcompare OWNER TO ashutoshpg;

--
-- Name: casttesttype; Type: SHELL TYPE; Schema: public; Owner: ashutoshpg
--

CREATE TYPE public.casttesttype;


--
-- Name: casttesttype_in(cstring); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.casttesttype_in(cstring) RETURNS public.casttesttype
    LANGUAGE internal IMMUTABLE STRICT
    AS $$textin$$;


ALTER FUNCTION public.casttesttype_in(cstring) OWNER TO ashutoshpg;

--
-- Name: casttesttype_out(public.casttesttype); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.casttesttype_out(public.casttesttype) RETURNS cstring
    LANGUAGE internal IMMUTABLE STRICT
    AS $$textout$$;


ALTER FUNCTION public.casttesttype_out(public.casttesttype) OWNER TO ashutoshpg;

--
-- Name: casttesttype; Type: TYPE; Schema: public; Owner: ashutoshpg
--

CREATE TYPE public.casttesttype (
    INTERNALLENGTH = variable,
    INPUT = public.casttesttype_in,
    OUTPUT = public.casttesttype_out,
    ALIGNMENT = int4,
    STORAGE = plain
);


ALTER TYPE public.casttesttype OWNER TO ashutoshpg;

--
-- Name: city_budget; Type: SHELL TYPE; Schema: public; Owner: ashutoshpg
--

CREATE TYPE public.city_budget;


--
-- Name: int44in(cstring); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.int44in(cstring) RETURNS public.city_budget
    LANGUAGE c IMMUTABLE STRICT
    AS '/home/ashutoshpg/work/units/pg_dump_test/build/dev/src/test/regress/regress.so', 'int44in';


ALTER FUNCTION public.int44in(cstring) OWNER TO ashutoshpg;

--
-- Name: int44out(public.city_budget); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.int44out(public.city_budget) RETURNS cstring
    LANGUAGE c IMMUTABLE STRICT
    AS '/home/ashutoshpg/work/units/pg_dump_test/build/dev/src/test/regress/regress.so', 'int44out';


ALTER FUNCTION public.int44out(public.city_budget) OWNER TO ashutoshpg;

--
-- Name: city_budget; Type: TYPE; Schema: public; Owner: ashutoshpg
--

CREATE TYPE public.city_budget (
    INTERNALLENGTH = 16,
    INPUT = public.int44in,
    OUTPUT = public.int44out,
    SUBSCRIPT = raw_array_subscript_handler,
    ELEMENT = integer,
    CATEGORY = 'x',
    PREFERRED = true,
    ALIGNMENT = int4,
    STORAGE = plain
);


ALTER TYPE public.city_budget OWNER TO ashutoshpg;

--
-- Name: complex; Type: TYPE; Schema: public; Owner: ashutoshpg
--

CREATE TYPE public.complex AS (
	r double precision,
	i double precision
);


ALTER TYPE public.complex OWNER TO ashutoshpg;

--
-- Name: con; Type: DOMAIN; Schema: public; Owner: ashutoshpg
--

CREATE DOMAIN public.con AS integer
	CONSTRAINT con_check CHECK ((VALUE > 0));


ALTER DOMAIN public.con OWNER TO ashutoshpg;

--
-- Name: dom; Type: DOMAIN; Schema: public; Owner: ashutoshpg
--

CREATE DOMAIN public.dom AS integer;


ALTER DOMAIN public.dom OWNER TO ashutoshpg;

--
-- Name: float8range; Type: TYPE; Schema: public; Owner: ashutoshpg
--

CREATE TYPE public.float8range AS RANGE (
    subtype = double precision,
    multirange_type_name = public.float8multirange,
    subtype_diff = float8mi
);


ALTER TYPE public.float8range OWNER TO ashutoshpg;

--
-- Name: insenum; Type: TYPE; Schema: public; Owner: ashutoshpg
--

CREATE TYPE public.insenum AS ENUM (
    'L1',
    'i1',
    'i2',
    'i3',
    'i4',
    'i5',
    'i6',
    'i7',
    'i8',
    'i9',
    'i10',
    'i11',
    'i12',
    'i13',
    'i14',
    'i15',
    'i16',
    'i17',
    'i18',
    'i19',
    'i20',
    'i21',
    'i22',
    'i23',
    'i24',
    'i25',
    'i26',
    'i27',
    'i28',
    'i29',
    'i30',
    'L2'
);


ALTER TYPE public.insenum OWNER TO ashutoshpg;

--
-- Name: int42; Type: SHELL TYPE; Schema: public; Owner: ashutoshpg
--

CREATE TYPE public.int42;


--
-- Name: int42_in(cstring); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.int42_in(cstring) RETURNS public.int42
    LANGUAGE internal IMMUTABLE STRICT
    AS $$int4in$$;


ALTER FUNCTION public.int42_in(cstring) OWNER TO ashutoshpg;

--
-- Name: int42_out(public.int42); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.int42_out(public.int42) RETURNS cstring
    LANGUAGE internal IMMUTABLE STRICT
    AS $$int4out$$;


ALTER FUNCTION public.int42_out(public.int42) OWNER TO ashutoshpg;

--
-- Name: int42; Type: TYPE; Schema: public; Owner: ashutoshpg
--

CREATE TYPE public.int42 (
    INTERNALLENGTH = 4,
    INPUT = public.int42_in,
    OUTPUT = public.int42_out,
    DEFAULT = '42',
    ALIGNMENT = int4,
    STORAGE = plain,
    PASSEDBYVALUE
);


ALTER TYPE public.int42 OWNER TO ashutoshpg;

--
-- Name: int8alias1; Type: SHELL TYPE; Schema: public; Owner: ashutoshpg
--

CREATE TYPE public.int8alias1;


--
-- Name: int8alias1in(cstring); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.int8alias1in(cstring) RETURNS public.int8alias1
    LANGUAGE internal IMMUTABLE STRICT
    AS $$int8in$$;


ALTER FUNCTION public.int8alias1in(cstring) OWNER TO ashutoshpg;

--
-- Name: int8alias1out(public.int8alias1); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.int8alias1out(public.int8alias1) RETURNS cstring
    LANGUAGE internal IMMUTABLE STRICT
    AS $$int8out$$;


ALTER FUNCTION public.int8alias1out(public.int8alias1) OWNER TO ashutoshpg;

--
-- Name: int8alias1; Type: TYPE; Schema: public; Owner: ashutoshpg
--

CREATE TYPE public.int8alias1 (
    INTERNALLENGTH = 8,
    INPUT = public.int8alias1in,
    OUTPUT = public.int8alias1out,
    ALIGNMENT = double,
    STORAGE = plain,
    PASSEDBYVALUE
);


ALTER TYPE public.int8alias1 OWNER TO ashutoshpg;

--
-- Name: int8alias2; Type: SHELL TYPE; Schema: public; Owner: ashutoshpg
--

CREATE TYPE public.int8alias2;


--
-- Name: int8alias2in(cstring); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.int8alias2in(cstring) RETURNS public.int8alias2
    LANGUAGE internal IMMUTABLE STRICT
    AS $$int8in$$;


ALTER FUNCTION public.int8alias2in(cstring) OWNER TO ashutoshpg;

--
-- Name: int8alias2out(public.int8alias2); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.int8alias2out(public.int8alias2) RETURNS cstring
    LANGUAGE internal IMMUTABLE STRICT
    AS $$int8out$$;


ALTER FUNCTION public.int8alias2out(public.int8alias2) OWNER TO ashutoshpg;

--
-- Name: int8alias2; Type: TYPE; Schema: public; Owner: ashutoshpg
--

CREATE TYPE public.int8alias2 (
    INTERNALLENGTH = 8,
    INPUT = public.int8alias2in,
    OUTPUT = public.int8alias2out,
    ALIGNMENT = double,
    STORAGE = plain,
    PASSEDBYVALUE
);


ALTER TYPE public.int8alias2 OWNER TO ashutoshpg;

--
-- Name: jbpop; Type: TYPE; Schema: public; Owner: ashutoshpg
--

CREATE TYPE public.jbpop AS (
	a text,
	b integer,
	c timestamp without time zone
);


ALTER TYPE public.jbpop OWNER TO ashutoshpg;

--
-- Name: jpop; Type: TYPE; Schema: public; Owner: ashutoshpg
--

CREATE TYPE public.jpop AS (
	a text,
	b integer,
	c timestamp without time zone
);


ALTER TYPE public.jpop OWNER TO ashutoshpg;

--
-- Name: jpop2; Type: TYPE; Schema: public; Owner: ashutoshpg
--

CREATE TYPE public.jpop2 AS (
	a integer,
	b json,
	c integer,
	d integer
);


ALTER TYPE public.jpop2 OWNER TO ashutoshpg;

--
-- Name: mynums; Type: DOMAIN; Schema: public; Owner: ashutoshpg
--

CREATE DOMAIN public.mynums AS numeric(4,2)[];


ALTER DOMAIN public.mynums OWNER TO ashutoshpg;

--
-- Name: mynums2; Type: DOMAIN; Schema: public; Owner: ashutoshpg
--

CREATE DOMAIN public.mynums2 AS public.mynums;


ALTER DOMAIN public.mynums2 OWNER TO ashutoshpg;

--
-- Name: myshell; Type: TYPE; Schema: public; Owner: ashutoshpg
--

CREATE TYPE public.myshell;


ALTER TYPE public.myshell OWNER TO ashutoshpg;

--
-- Name: orderedarray; Type: DOMAIN; Schema: public; Owner: ashutoshpg
--

CREATE DOMAIN public.orderedarray AS integer[]
	CONSTRAINT sorted CHECK (((VALUE)[1] < (VALUE)[2]));


ALTER DOMAIN public.orderedarray OWNER TO ashutoshpg;

--
-- Name: orderedpair; Type: DOMAIN; Schema: public; Owner: ashutoshpg
--

CREATE DOMAIN public.orderedpair AS integer[]
	CONSTRAINT orderedpair_check CHECK (((VALUE)[1] < (VALUE)[2]));


ALTER DOMAIN public.orderedpair OWNER TO ashutoshpg;

--
-- Name: person_type; Type: TYPE; Schema: public; Owner: ashutoshpg
--

CREATE TYPE public.person_type AS (
	id integer,
	name text
);


ALTER TYPE public.person_type OWNER TO ashutoshpg;

--
-- Name: planets; Type: TYPE; Schema: public; Owner: ashutoshpg
--

CREATE TYPE public.planets AS ENUM (
    'mercury',
    'venus',
    'earth',
    'mars',
    'jupiter',
    'saturn',
    'uranus',
    'neptune',
    'pluto'
);


ALTER TYPE public.planets OWNER TO ashutoshpg;

--
-- Name: plpgsql_arr_domain_check(integer[]); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.plpgsql_arr_domain_check(val integer[]) RETURNS boolean
    LANGUAGE plpgsql IMMUTABLE
    AS $$
begin return val[1] > 0; end
$$;


ALTER FUNCTION public.plpgsql_arr_domain_check(val integer[]) OWNER TO ashutoshpg;

--
-- Name: plpgsql_arr_domain; Type: DOMAIN; Schema: public; Owner: ashutoshpg
--

CREATE DOMAIN public.plpgsql_arr_domain AS integer[]
	CONSTRAINT plpgsql_arr_domain_check CHECK (public.plpgsql_arr_domain_check(VALUE));


ALTER DOMAIN public.plpgsql_arr_domain OWNER TO ashutoshpg;

--
-- Name: plpgsql_domain_check(integer); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.plpgsql_domain_check(val integer) RETURNS boolean
    LANGUAGE plpgsql IMMUTABLE
    AS $$
begin return val > 0; end
$$;


ALTER FUNCTION public.plpgsql_domain_check(val integer) OWNER TO ashutoshpg;

--
-- Name: plpgsql_domain; Type: DOMAIN; Schema: public; Owner: ashutoshpg
--

CREATE DOMAIN public.plpgsql_domain AS integer
	CONSTRAINT plpgsql_domain_check CHECK (public.plpgsql_domain_check(VALUE));


ALTER DOMAIN public.plpgsql_domain OWNER TO ashutoshpg;

--
-- Name: pos_int; Type: DOMAIN; Schema: public; Owner: ashutoshpg
--

CREATE DOMAIN public.pos_int AS integer NOT NULL
	CONSTRAINT pos_int_check CHECK ((VALUE > 0));


ALTER DOMAIN public.pos_int OWNER TO ashutoshpg;

--
-- Name: quad; Type: TYPE; Schema: public; Owner: ashutoshpg
--

CREATE TYPE public.quad AS (
	c1 public.complex,
	c2 public.complex
);


ALTER TYPE public.quad OWNER TO ashutoshpg;

--
-- Name: rainbow; Type: TYPE; Schema: public; Owner: ashutoshpg
--

CREATE TYPE public.rainbow AS ENUM (
    'red',
    'orange',
    'yellow',
    'green',
    'blue',
    'purple'
);


ALTER TYPE public.rainbow OWNER TO ashutoshpg;

--
-- Name: record_type; Type: TYPE; Schema: public; Owner: ashutoshpg
--

CREATE TYPE public.record_type AS (
	x text,
	y integer,
	z boolean
);


ALTER TYPE public.record_type OWNER TO ashutoshpg;

--
-- Name: rewritetype; Type: TYPE; Schema: public; Owner: ashutoshpg
--

CREATE TYPE public.rewritetype AS (
	a text
);


ALTER TYPE public.rewritetype OWNER TO ashutoshpg;

--
-- Name: rgb; Type: DOMAIN; Schema: public; Owner: ashutoshpg
--

CREATE DOMAIN public.rgb AS public.rainbow
	CONSTRAINT rgb_check CHECK ((VALUE = ANY (ARRAY['red'::public.rainbow, 'green'::public.rainbow, 'blue'::public.rainbow])));


ALTER DOMAIN public.rgb OWNER TO ashutoshpg;

--
-- Name: rngfunc_rescan_t; Type: TYPE; Schema: public; Owner: ashutoshpg
--

CREATE TYPE public.rngfunc_rescan_t AS (
	i integer,
	s bigint
);


ALTER TYPE public.rngfunc_rescan_t OWNER TO ashutoshpg;

--
-- Name: spgist_text; Type: DOMAIN; Schema: public; Owner: ashutoshpg
--

CREATE DOMAIN public.spgist_text AS character varying;


ALTER DOMAIN public.spgist_text OWNER TO ashutoshpg;

--
-- Name: sqljson_char2; Type: DOMAIN; Schema: public; Owner: ashutoshpg
--

CREATE DOMAIN public.sqljson_char2 AS character(2)
	CONSTRAINT sqljson_char2_check CHECK ((VALUE <> '12'::bpchar));


ALTER DOMAIN public.sqljson_char2 OWNER TO ashutoshpg;

--
-- Name: sqljsonb_int_not_null; Type: DOMAIN; Schema: public; Owner: ashutoshpg
--

CREATE DOMAIN public.sqljsonb_int_not_null AS integer NOT NULL;


ALTER DOMAIN public.sqljsonb_int_not_null OWNER TO ashutoshpg;

--
-- Name: sqljsonb_rec; Type: TYPE; Schema: public; Owner: ashutoshpg
--

CREATE TYPE public.sqljsonb_rec AS (
	a integer,
	t text,
	js json,
	jb jsonb,
	jsa json[]
);


ALTER TYPE public.sqljsonb_rec OWNER TO ashutoshpg;

--
-- Name: sqljsonb_reca; Type: TYPE; Schema: public; Owner: ashutoshpg
--

CREATE TYPE public.sqljsonb_reca AS (
	reca public.sqljsonb_rec[]
);


ALTER TYPE public.sqljsonb_reca OWNER TO ashutoshpg;

--
-- Name: stoplight; Type: TYPE; Schema: public; Owner: ashutoshpg
--

CREATE TYPE public.stoplight AS ENUM (
    'red',
    'yellow',
    'green'
);


ALTER TYPE public.stoplight OWNER TO ashutoshpg;

--
-- Name: str_domain; Type: DOMAIN; Schema: public; Owner: ashutoshpg
--

CREATE DOMAIN public.str_domain AS text NOT NULL;


ALTER DOMAIN public.str_domain OWNER TO ashutoshpg;

--
-- Name: str_domain2; Type: DOMAIN; Schema: public; Owner: ashutoshpg
--

CREATE DOMAIN public.str_domain2 AS text DEFAULT 'foo'::text
	CONSTRAINT str_domain2_check CHECK ((VALUE <> 'foo'::text));


ALTER DOMAIN public.str_domain2 OWNER TO ashutoshpg;

--
-- Name: test_type3; Type: TYPE; Schema: public; Owner: ashutoshpg
--

CREATE TYPE public.test_type3 AS (
	b integer
);


ALTER TYPE public.test_type3 OWNER TO ashutoshpg;

--
-- Name: testboolxmldomain; Type: DOMAIN; Schema: public; Owner: ashutoshpg
--

CREATE DOMAIN public.testboolxmldomain AS boolean;


ALTER DOMAIN public.testboolxmldomain OWNER TO ashutoshpg;

--
-- Name: testdatexmldomain; Type: DOMAIN; Schema: public; Owner: ashutoshpg
--

CREATE DOMAIN public.testdatexmldomain AS date;


ALTER DOMAIN public.testdatexmldomain OWNER TO ashutoshpg;

--
-- Name: testxmldomain; Type: DOMAIN; Schema: public; Owner: ashutoshpg
--

CREATE DOMAIN public.testxmldomain AS character varying;


ALTER DOMAIN public.testxmldomain OWNER TO ashutoshpg;

--
-- Name: text_w_default; Type: SHELL TYPE; Schema: public; Owner: ashutoshpg
--

CREATE TYPE public.text_w_default;


--
-- Name: text_w_default_in(cstring); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.text_w_default_in(cstring) RETURNS public.text_w_default
    LANGUAGE internal IMMUTABLE STRICT
    AS $$textin$$;


ALTER FUNCTION public.text_w_default_in(cstring) OWNER TO ashutoshpg;

--
-- Name: text_w_default_out(public.text_w_default); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.text_w_default_out(public.text_w_default) RETURNS cstring
    LANGUAGE internal IMMUTABLE STRICT
    AS $$textout$$;


ALTER FUNCTION public.text_w_default_out(public.text_w_default) OWNER TO ashutoshpg;

--
-- Name: text_w_default; Type: TYPE; Schema: public; Owner: ashutoshpg
--

CREATE TYPE public.text_w_default (
    INTERNALLENGTH = variable,
    INPUT = public.text_w_default_in,
    OUTPUT = public.text_w_default_out,
    DEFAULT = 'zippo',
    ALIGNMENT = int4,
    STORAGE = plain
);


ALTER TYPE public.text_w_default OWNER TO ashutoshpg;

--
-- Name: textrange; Type: TYPE; Schema: public; Owner: ashutoshpg
--

CREATE TYPE public.textrange AS RANGE (
    subtype = text,
    multirange_type_name = public.textmultirange,
    collation = pg_catalog."C"
);


ALTER TYPE public.textrange OWNER TO ashutoshpg;

--
-- Name: things; Type: DOMAIN; Schema: public; Owner: ashutoshpg
--

CREATE DOMAIN public.things AS integer
	CONSTRAINT meow CHECK ((VALUE < 11));


ALTER DOMAIN public.things OWNER TO ashutoshpg;

--
-- Name: tt_t0; Type: TYPE; Schema: public; Owner: ashutoshpg
--

CREATE TYPE public.tt_t0 AS (
	x integer,
	y numeric(8,2)
);


ALTER TYPE public.tt_t0 OWNER TO ashutoshpg;

--
-- Name: tt_t1; Type: TYPE; Schema: public; Owner: ashutoshpg
--

CREATE TYPE public.tt_t1 AS (
	x integer,
	y numeric(8,2)
);


ALTER TYPE public.tt_t1 OWNER TO ashutoshpg;

--
-- Name: varbitrange; Type: TYPE; Schema: public; Owner: ashutoshpg
--

CREATE TYPE public.varbitrange AS RANGE (
    subtype = bit varying,
    multirange_type_name = public.varbitmultirange
);


ALTER TYPE public.varbitrange OWNER TO ashutoshpg;

--
-- Name: widget; Type: SHELL TYPE; Schema: public; Owner: ashutoshpg
--

CREATE TYPE public.widget;


--
-- Name: widget_in(cstring); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.widget_in(cstring) RETURNS public.widget
    LANGUAGE c IMMUTABLE STRICT
    AS '/home/ashutoshpg/work/units/pg_dump_test/build/dev/src/test/regress/regress.so', 'widget_in';


ALTER FUNCTION public.widget_in(cstring) OWNER TO ashutoshpg;

--
-- Name: widget_out(public.widget); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.widget_out(public.widget) RETURNS cstring
    LANGUAGE c IMMUTABLE STRICT
    AS '/home/ashutoshpg/work/units/pg_dump_test/build/dev/src/test/regress/regress.so', 'widget_out';


ALTER FUNCTION public.widget_out(public.widget) OWNER TO ashutoshpg;

--
-- Name: widget; Type: TYPE; Schema: public; Owner: ashutoshpg
--

CREATE TYPE public.widget (
    INTERNALLENGTH = 24,
    INPUT = public.widget_in,
    OUTPUT = public.widget_out,
    TYPMOD_IN = numerictypmodin,
    TYPMOD_OUT = numerictypmodout,
    ALIGNMENT = double,
    STORAGE = plain
);


ALTER TYPE public.widget OWNER TO ashutoshpg;

--
-- Name: CAST (text AS public.casttesttype); Type: CAST; Schema: -; Owner: -
--

CREATE CAST (text AS public.casttesttype) WITHOUT FUNCTION AS IMPLICIT;


--
-- Name: bar_int4_text(integer); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.bar_int4_text(integer) RETURNS text
    LANGUAGE sql
    AS $_$ SELECT ('bar'::text || $1::text); $_$;


ALTER FUNCTION public.bar_int4_text(integer) OWNER TO ashutoshpg;

--
-- Name: CAST (integer AS public.casttesttype); Type: CAST; Schema: -; Owner: -
--

CREATE CAST (integer AS public.casttesttype) WITH FUNCTION public.bar_int4_text(integer) AS IMPLICIT;


--
-- Name: CAST (bigint AS public.int8alias1); Type: CAST; Schema: -; Owner: -
--

CREATE CAST (bigint AS public.int8alias1) WITHOUT FUNCTION;


--
-- Name: CAST (bigint AS public.int8alias2); Type: CAST; Schema: -; Owner: -
--

CREATE CAST (bigint AS public.int8alias2) WITHOUT FUNCTION;


--
-- Name: CAST (public.int8alias1 AS bigint); Type: CAST; Schema: -; Owner: -
--

CREATE CAST (public.int8alias1 AS bigint) WITHOUT FUNCTION;


--
-- Name: CAST (public.int8alias2 AS bigint); Type: CAST; Schema: -; Owner: -
--

CREATE CAST (public.int8alias2 AS bigint) WITHOUT FUNCTION;


--
-- Name: gtest_trigger_func(); Type: FUNCTION; Schema: generated_stored_tests; Owner: ashutoshpg
--

CREATE FUNCTION generated_stored_tests.gtest_trigger_func() RETURNS trigger
    LANGUAGE plpgsql
    AS $$
BEGIN
  IF tg_op IN ('DELETE', 'UPDATE') THEN
    RAISE INFO '%: %: old = %', TG_NAME, TG_WHEN, OLD;
  END IF;
  IF tg_op IN ('INSERT', 'UPDATE') THEN
    RAISE INFO '%: %: new = %', TG_NAME, TG_WHEN, NEW;
  END IF;
  IF tg_op = 'DELETE' THEN
    RETURN OLD;
  ELSE
    RETURN NEW;
  END IF;
END
$$;


ALTER FUNCTION generated_stored_tests.gtest_trigger_func() OWNER TO ashutoshpg;

--
-- Name: gtest_trigger_func3(); Type: FUNCTION; Schema: generated_stored_tests; Owner: ashutoshpg
--

CREATE FUNCTION generated_stored_tests.gtest_trigger_func3() RETURNS trigger
    LANGUAGE plpgsql
    AS $$
BEGIN
  RAISE NOTICE 'OK';
  RETURN NEW;
END
$$;


ALTER FUNCTION generated_stored_tests.gtest_trigger_func3() OWNER TO ashutoshpg;

--
-- Name: gtest_trigger_func4(); Type: FUNCTION; Schema: generated_stored_tests; Owner: ashutoshpg
--

CREATE FUNCTION generated_stored_tests.gtest_trigger_func4() RETURNS trigger
    LANGUAGE plpgsql
    AS $$
BEGIN
  NEW.a = 10;
  NEW.b = 300;
  RETURN NEW;
END;
$$;


ALTER FUNCTION generated_stored_tests.gtest_trigger_func4() OWNER TO ashutoshpg;

--
-- Name: mvtest_drop_the_index(); Type: FUNCTION; Schema: mvtest_mvschema; Owner: ashutoshpg
--

CREATE FUNCTION mvtest_mvschema.mvtest_drop_the_index() RETURNS boolean
    LANGUAGE plpgsql
    AS $$
BEGIN
  EXECUTE 'DROP INDEX IF EXISTS mvtest_mvschema.mvtest_drop_idx';
  RETURN true;
END;
$$;


ALTER FUNCTION mvtest_mvschema.mvtest_drop_the_index() OWNER TO ashutoshpg;

--
-- Name: add_group(anyarray, anyelement, integer); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.add_group(grp anyarray, ad anyelement, size integer) RETURNS anyarray
    LANGUAGE plpgsql IMMUTABLE
    AS $$
begin
  if grp is null then
    return array[ad];
  end if;
  if array_upper(grp, 1) < size then
    return grp || ad;
  end if;
  return grp;
end;
$$;


ALTER FUNCTION public.add_group(grp anyarray, ad anyelement, size integer) OWNER TO ashutoshpg;

--
-- Name: aggf_trans(public.aggtype[], integer, integer, text); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.aggf_trans(public.aggtype[], integer, integer, text) RETURNS public.aggtype[]
    LANGUAGE sql IMMUTABLE STRICT
    AS $_$select array_append($1,ROW($2,$3,$4)::aggtype)$_$;


ALTER FUNCTION public.aggf_trans(public.aggtype[], integer, integer, text) OWNER TO ashutoshpg;

--
-- Name: aggfns_trans(public.aggtype[], integer, integer, text); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.aggfns_trans(public.aggtype[], integer, integer, text) RETURNS public.aggtype[]
    LANGUAGE sql IMMUTABLE
    AS $_$select array_append($1,ROW($2,$3,$4)::aggtype)$_$;


ALTER FUNCTION public.aggfns_trans(public.aggtype[], integer, integer, text) OWNER TO ashutoshpg;

--
-- Name: alter_table_under_transition_tables_upd_func(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.alter_table_under_transition_tables_upd_func() RETURNS trigger
    LANGUAGE plpgsql
    AS $$
BEGIN
  RAISE WARNING 'old table = %, new table = %',
                  (SELECT string_agg(id || '=' || name, ',') FROM d),
                  (SELECT string_agg(id || '=' || name, ',') FROM i);
  RAISE NOTICE 'one = %', (SELECT 1 FROM alter_table_under_transition_tables LIMIT 1);
  RETURN NULL;
END;
$$;


ALTER FUNCTION public.alter_table_under_transition_tables_upd_func() OWNER TO ashutoshpg;

--
-- Name: array_to_set(anyarray); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.array_to_set(anyarray) RETURNS SETOF record
    LANGUAGE sql IMMUTABLE
    AS $_$
  select i AS "index", $1[i] AS "value" from generate_subscripts($1, 1) i
$_$;


ALTER FUNCTION public.array_to_set(anyarray) OWNER TO ashutoshpg;

--
-- Name: autoinc(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.autoinc() RETURNS trigger
    LANGUAGE c
    AS '/home/ashutoshpg/work/units/pg_dump_test/build/dev/src/test/regress/autoinc.so', 'autoinc';


ALTER FUNCTION public.autoinc() OWNER TO ashutoshpg;

--
-- Name: binary_coercible(oid, oid); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.binary_coercible(oid, oid) RETURNS boolean
    LANGUAGE c STABLE STRICT PARALLEL SAFE
    AS '/home/ashutoshpg/work/units/pg_dump_test/build/dev/src/test/regress/regress.so', 'binary_coercible';


ALTER FUNCTION public.binary_coercible(oid, oid) OWNER TO ashutoshpg;

--
-- Name: bleat(integer); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.bleat(integer) RETURNS integer
    LANGUAGE plpgsql
    AS $_$
begin
  raise notice 'bleat %', $1;
  return $1;
end$_$;


ALTER FUNCTION public.bleat(integer) OWNER TO ashutoshpg;

--
-- Name: boo(integer); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.boo(integer) RETURNS integer
    LANGUAGE plpgsql IMMUTABLE STRICT
    AS $_$ BEGIN RAISE NOTICE 'boo: %', $1; RETURN $1; END; $_$;


ALTER FUNCTION public.boo(integer) OWNER TO ashutoshpg;

--
-- Name: cache_test(integer); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.cache_test(integer) RETURNS integer
    LANGUAGE plpgsql
    AS $_$
declare total int;
begin
	create temp table t1(f1 int);
	insert into t1 values($1);
	insert into t1 values(11);
	insert into t1 values(12);
	insert into t1 values(13);
	select sum(f1) into total from t1;
	drop table t1;
	return total;
end
$_$;


ALTER FUNCTION public.cache_test(integer) OWNER TO ashutoshpg;

--
-- Name: cache_test_2(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.cache_test_2() RETURNS integer
    LANGUAGE plpgsql
    AS $$
begin
	return f1 from v1;
end$$;


ALTER FUNCTION public.cache_test_2() OWNER TO ashutoshpg;

--
-- Name: cachebug(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.cachebug() RETURNS void
    LANGUAGE plpgsql
    AS $$
declare r int;
begin
  drop table if exists temptable cascade;
  create temp table temptable as select * from generate_series(1,3) as f1;
  create temp view vv as select * from temptable;
  for r in select * from vv loop
    raise notice '%', r;
  end loop;
end$$;


ALTER FUNCTION public.cachebug() OWNER TO ashutoshpg;

--
-- Name: casttestfunc(public.casttesttype); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.casttestfunc(public.casttesttype) RETURNS integer
    LANGUAGE sql
    AS $$ SELECT 1; $$;


ALTER FUNCTION public.casttestfunc(public.casttesttype) OWNER TO ashutoshpg;



--
-- Name: check_con_tbl; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.check_con_tbl (
    f1 integer
);


ALTER TABLE public.check_con_tbl OWNER TO ashutoshpg;

--
-- Name: check_con_function(public.check_con_tbl); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.check_con_function(public.check_con_tbl) RETURNS boolean
    LANGUAGE plpgsql IMMUTABLE
    AS $_$
begin
  raise notice 'input = %', row_to_json($1);
  return $1.f1 > 0;
end $_$;


ALTER FUNCTION public.check_con_function(public.check_con_tbl) OWNER TO ashutoshpg;

--
-- Name: check_estimated_rows(text); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.check_estimated_rows(text) RETURNS TABLE(estimated integer, actual integer)
    LANGUAGE plpgsql
    AS $_$
declare
    ln text;
    tmp text[];
    first_row bool := true;
begin
    for ln in
        execute format('explain analyze %s', $1)
    loop
        if first_row then
            first_row := false;
            tmp := regexp_match(ln, 'rows=(\d*) .* rows=(\d*)');
            return query select tmp[1]::int, tmp[2]::int;
        end if;
    end loop;
end;
$_$;


ALTER FUNCTION public.check_estimated_rows(text) OWNER TO ashutoshpg;

--
-- Name: check_foreign_key(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.check_foreign_key() RETURNS trigger
    LANGUAGE c
    AS '/home/ashutoshpg/work/units/pg_dump_test/build/dev/src/test/regress/refint.so', 'check_foreign_key';


ALTER FUNCTION public.check_foreign_key() OWNER TO ashutoshpg;

--
-- Name: check_primary_key(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.check_primary_key() RETURNS trigger
    LANGUAGE c
    AS '/home/ashutoshpg/work/units/pg_dump_test/build/dev/src/test/regress/refint.so', 'check_primary_key';


ALTER FUNCTION public.check_primary_key() OWNER TO ashutoshpg;

--
-- Name: city_delete(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.city_delete() RETURNS trigger
    LANGUAGE plpgsql
    AS $$
begin
    DELETE FROM city_table WHERE city_id = OLD.city_id;
    if NOT FOUND then RETURN NULL; end if;
    RETURN OLD;
end;
$$;


ALTER FUNCTION public.city_delete() OWNER TO ashutoshpg;

--
-- Name: city_insert(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.city_insert() RETURNS trigger
    LANGUAGE plpgsql
    AS $$
declare
    ctry_id int;
begin
    if NEW.country_name IS NOT NULL then
        SELECT country_id, continent INTO ctry_id, NEW.continent
            FROM country_table WHERE country_name = NEW.country_name;
        if NOT FOUND then
            raise exception 'No such country: "%"', NEW.country_name;
        end if;
    else
        NEW.continent := NULL;
    end if;

    if NEW.city_id IS NOT NULL then
        INSERT INTO city_table
            VALUES(NEW.city_id, NEW.city_name, NEW.population, ctry_id);
    else
        INSERT INTO city_table(city_name, population, country_id)
            VALUES(NEW.city_name, NEW.population, ctry_id)
            RETURNING city_id INTO NEW.city_id;
    end if;

    RETURN NEW;
end;
$$;


ALTER FUNCTION public.city_insert() OWNER TO ashutoshpg;

--
-- Name: city_update(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.city_update() RETURNS trigger
    LANGUAGE plpgsql
    AS $$
declare
    ctry_id int;
begin
    if NEW.country_name IS DISTINCT FROM OLD.country_name then
        SELECT country_id, continent INTO ctry_id, NEW.continent
            FROM country_table WHERE country_name = NEW.country_name;
        if NOT FOUND then
            raise exception 'No such country: "%"', NEW.country_name;
        end if;

        UPDATE city_table SET city_name = NEW.city_name,
                              population = NEW.population,
                              country_id = ctry_id
            WHERE city_id = OLD.city_id;
    else
        UPDATE city_table SET city_name = NEW.city_name,
                              population = NEW.population
            WHERE city_id = OLD.city_id;
        NEW.continent := OLD.continent;
    end if;

    if NOT FOUND then RETURN NULL; end if;
    RETURN NEW;
end;
$$;


ALTER FUNCTION public.city_update() OWNER TO ashutoshpg;

--
-- Name: cleast_accum(anycompatible, anycompatiblearray); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.cleast_accum(anycompatible, VARIADIC anycompatiblearray) RETURNS anycompatible
    LANGUAGE sql
    AS $_$select least($1, min($2[i])) from generate_subscripts($2,1) g(i)$_$;


ALTER FUNCTION public.cleast_accum(anycompatible, VARIADIC anycompatiblearray) OWNER TO ashutoshpg;

--
-- Name: constant_refcursor(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.constant_refcursor() RETURNS refcursor
    LANGUAGE plpgsql
    AS $$
declare
    rc constant refcursor := 'my_cursor_name';
begin
    open rc for select a from rc_test;
    return rc;
end
$$;


ALTER FUNCTION public.constant_refcursor() OWNER TO ashutoshpg;

--
-- Name: consumes_rw_array(integer[]); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.consumes_rw_array(integer[]) RETURNS integer
    LANGUAGE plpgsql STABLE
    AS $_$
  begin return $1[1]; end;
$_$;


ALTER FUNCTION public.consumes_rw_array(integer[]) OWNER TO ashutoshpg;

--
-- Name: distinct_func(integer); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.distinct_func(a integer) RETURNS integer
    LANGUAGE plpgsql PARALLEL SAFE
    AS $$
  BEGIN
    RETURN a;
  END;
$$;


ALTER FUNCTION public.distinct_func(a integer) OWNER TO ashutoshpg;

--
-- Name: do_analyze(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.do_analyze() RETURNS void
    LANGUAGE sql
    AS $$ANALYZE pg_am$$;


ALTER FUNCTION public.do_analyze() OWNER TO ashutoshpg;

--
-- Name: doubledecrement(public.pos_int); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.doubledecrement(p1 public.pos_int) RETURNS public.pos_int
    LANGUAGE plpgsql
    AS $$
declare v pos_int := 1;
begin
    v := p1 - 1;
    return v - 1;
end$$;


ALTER FUNCTION public.doubledecrement(p1 public.pos_int) OWNER TO ashutoshpg;

--
-- Name: drop_sql_command(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.drop_sql_command() RETURNS event_trigger
    LANGUAGE plpgsql
    AS $$
BEGIN
RAISE NOTICE '% - sql_drop', tg_tag;
END;
$$;


ALTER FUNCTION public.drop_sql_command() OWNER TO ashutoshpg;

--
-- Name: dummy_update_func(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.dummy_update_func() RETURNS trigger
    LANGUAGE plpgsql
    AS $$
BEGIN
  RAISE NOTICE 'dummy_update_func(%) called: action = %, old = %, new = %',
    TG_ARGV[0], TG_OP, OLD, NEW;
  RETURN NEW;
END;
$$;


ALTER FUNCTION public.dummy_update_func() OWNER TO ashutoshpg;

--
-- Name: end_command(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.end_command() RETURNS event_trigger
    LANGUAGE plpgsql
    AS $$
BEGIN
RAISE NOTICE '% - ddl_command_end', tg_tag;
END;
$$;


ALTER FUNCTION public.end_command() OWNER TO ashutoshpg;

--
-- Name: equipment_r; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.equipment_r (
    name text,
    hobby text
);


ALTER TABLE public.equipment_r OWNER TO ashutoshpg;

--
-- Name: hobbies_r; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.hobbies_r (
    name text,
    person text
);


ALTER TABLE public.hobbies_r OWNER TO ashutoshpg;

--
-- Name: equipment(public.hobbies_r); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.equipment(public.hobbies_r) RETURNS SETOF public.equipment_r
    LANGUAGE sql
    AS $_$select * from equipment_r where hobby = $1.name$_$;


ALTER FUNCTION public.equipment(public.hobbies_r) OWNER TO ashutoshpg;

--
-- Name: equipment_named(public.hobbies_r); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.equipment_named(hobby public.hobbies_r) RETURNS SETOF public.equipment_r
    LANGUAGE sql
    AS $$select * from equipment_r where equipment_r.hobby = equipment_named.hobby.name$$;


ALTER FUNCTION public.equipment_named(hobby public.hobbies_r) OWNER TO ashutoshpg;

--
-- Name: equipment_named_ambiguous_1a(public.hobbies_r); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.equipment_named_ambiguous_1a(hobby public.hobbies_r) RETURNS SETOF public.equipment_r
    LANGUAGE sql
    AS $$select * from equipment_r where hobby = equipment_named_ambiguous_1a.hobby.name$$;


ALTER FUNCTION public.equipment_named_ambiguous_1a(hobby public.hobbies_r) OWNER TO ashutoshpg;

--
-- Name: equipment_named_ambiguous_1b(public.hobbies_r); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.equipment_named_ambiguous_1b(hobby public.hobbies_r) RETURNS SETOF public.equipment_r
    LANGUAGE sql
    AS $$select * from equipment_r where equipment_r.hobby = hobby.name$$;


ALTER FUNCTION public.equipment_named_ambiguous_1b(hobby public.hobbies_r) OWNER TO ashutoshpg;

--
-- Name: equipment_named_ambiguous_1c(public.hobbies_r); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.equipment_named_ambiguous_1c(hobby public.hobbies_r) RETURNS SETOF public.equipment_r
    LANGUAGE sql
    AS $$select * from equipment_r where hobby = hobby.name$$;


ALTER FUNCTION public.equipment_named_ambiguous_1c(hobby public.hobbies_r) OWNER TO ashutoshpg;

--
-- Name: equipment_named_ambiguous_2a(text); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.equipment_named_ambiguous_2a(hobby text) RETURNS SETOF public.equipment_r
    LANGUAGE sql
    AS $$select * from equipment_r where hobby = equipment_named_ambiguous_2a.hobby$$;


ALTER FUNCTION public.equipment_named_ambiguous_2a(hobby text) OWNER TO ashutoshpg;

--
-- Name: equipment_named_ambiguous_2b(text); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.equipment_named_ambiguous_2b(hobby text) RETURNS SETOF public.equipment_r
    LANGUAGE sql
    AS $$select * from equipment_r where equipment_r.hobby = hobby$$;


ALTER FUNCTION public.equipment_named_ambiguous_2b(hobby text) OWNER TO ashutoshpg;

--
-- Name: eval(text); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.eval(expr text) RETURNS text
    LANGUAGE plpgsql
    AS $$
DECLARE
  result text;
BEGIN
  EXECUTE 'select '||expr INTO result;
  RETURN result;
EXCEPTION WHEN OTHERS THEN
  RETURN SQLERRM;
END
$$;


ALTER FUNCTION public.eval(expr text) OWNER TO ashutoshpg;

--
-- Name: event_trigger_report_dropped(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.event_trigger_report_dropped() RETURNS event_trigger
    LANGUAGE plpgsql
    AS $$
DECLARE r record;
BEGIN
    FOR r IN SELECT * from pg_event_trigger_dropped_objects()
    LOOP
    IF NOT r.normal AND NOT r.original THEN
        CONTINUE;
    END IF;
    RAISE NOTICE 'NORMAL: orig=% normal=% istemp=% type=% identity=% name=% args=%',
        r.original, r.normal, r.is_temporary, r.object_type,
        r.object_identity, r.address_names, r.address_args;
    END LOOP;
END; $$;


ALTER FUNCTION public.event_trigger_report_dropped() OWNER TO ashutoshpg;

--
-- Name: event_trigger_report_end(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.event_trigger_report_end() RETURNS event_trigger
    LANGUAGE plpgsql
    AS $$
DECLARE r RECORD;
BEGIN
    FOR r IN SELECT * FROM pg_event_trigger_ddl_commands()
    LOOP
        RAISE NOTICE 'END: command_tag=% type=% identity=%',
            r.command_tag, r.object_type, r.object_identity;
    END LOOP;
END; $$;


ALTER FUNCTION public.event_trigger_report_end() OWNER TO ashutoshpg;

--
-- Name: execute_into_test(character varying); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.execute_into_test(character varying) RETURNS record
    LANGUAGE plpgsql
    AS $_$
declare
    _r record;
    _rt eifoo%rowtype;
    _v eitype;
    i int;
    j int;
    k int;
begin
    execute 'insert into '||$1||' values(10,15)';
    execute 'select (row).* from (select row(10,1)::eifoo) s' into _r;
    raise notice '% %', _r.i, _r.y;
    execute 'select * from '||$1||' limit 1' into _rt;
    raise notice '% %', _rt.i, _rt.y;
    execute 'select *, 20 from '||$1||' limit 1' into i, j, k;
    raise notice '% % %', i, j, k;
    execute 'select 1,2' into _v;
    return _v;
end; $_$;


ALTER FUNCTION public.execute_into_test(character varying) OWNER TO ashutoshpg;

--
-- Name: execute_text_query_heap(text); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.execute_text_query_heap(query_sql text) RETURNS SETOF text
    LANGUAGE plpgsql
    AS $$
begin
  set enable_seqscan = on;
  set enable_bitmapscan = off;
  return query execute query_sql;
end;
$$;


ALTER FUNCTION public.execute_text_query_heap(query_sql text) OWNER TO ashutoshpg;

--
-- Name: execute_text_query_index(text); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.execute_text_query_index(query_sql text) RETURNS SETOF text
    LANGUAGE plpgsql
    AS $$
begin
  set enable_seqscan = off;
  set enable_bitmapscan = on;
  return query execute query_sql;
end;
$$;


ALTER FUNCTION public.execute_text_query_index(query_sql text) OWNER TO ashutoshpg;

--
-- Name: explain_analyze_inc_sort_nodes(text); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.explain_analyze_inc_sort_nodes(query text) RETURNS jsonb
    LANGUAGE plpgsql
    AS $$
declare
  elements jsonb;
  element jsonb;
  matching_nodes jsonb := '[]'::jsonb;
begin
  execute 'explain (analyze, costs off, summary off, timing off, format ''json'') ' || query into strict elements;
  while jsonb_array_length(elements) > 0 loop
    element := elements->0;
    elements := elements - 0;
    case jsonb_typeof(element)
    when 'array' then
      if jsonb_array_length(element) > 0 then
        elements := elements || element;
      end if;
    when 'object' then
      if element ? 'Plan' then
        elements := elements || jsonb_build_array(element->'Plan');
        element := element - 'Plan';
      else
        if element ? 'Plans' then
          elements := elements || jsonb_build_array(element->'Plans');
          element := element - 'Plans';
        end if;
        if (element->>'Node Type')::text = 'Incremental Sort' then
          matching_nodes := matching_nodes || element;
        end if;
      end if;
    end case;
  end loop;
  return matching_nodes;
end;
$$;


ALTER FUNCTION public.explain_analyze_inc_sort_nodes(query text) OWNER TO ashutoshpg;

--
-- Name: explain_analyze_inc_sort_nodes_verify_invariants(text); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.explain_analyze_inc_sort_nodes_verify_invariants(query text) RETURNS boolean
    LANGUAGE plpgsql
    AS $$
declare
  node jsonb;
  group_stats jsonb;
  group_key text;
  space_key text;
begin
  for node in select * from jsonb_array_elements(explain_analyze_inc_sort_nodes(query)) t loop
    for group_key in select unnest(array['Full-sort Groups', 'Pre-sorted Groups']::text[]) t loop
      group_stats := node->group_key;
      for space_key in select unnest(array['Sort Space Memory', 'Sort Space Disk']::text[]) t loop
        if (group_stats->space_key->'Peak Sort Space Used')::bigint < (group_stats->space_key->'Peak Sort Space Used')::bigint then
          raise exception '% has invalid max space < average space', group_key;
        end if;
      end loop;
    end loop;
  end loop;
  return true;
end;
$$;


ALTER FUNCTION public.explain_analyze_inc_sort_nodes_verify_invariants(query text) OWNER TO ashutoshpg;

--
-- Name: explain_analyze_inc_sort_nodes_without_memory(text); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.explain_analyze_inc_sort_nodes_without_memory(query text) RETURNS jsonb
    LANGUAGE plpgsql
    AS $$
declare
  nodes jsonb := '[]'::jsonb;
  node jsonb;
  group_key text;
  space_key text;
begin
  for node in select * from jsonb_array_elements(explain_analyze_inc_sort_nodes(query)) t loop
    for group_key in select unnest(array['Full-sort Groups', 'Pre-sorted Groups']::text[]) t loop
      for space_key in select unnest(array['Sort Space Memory', 'Sort Space Disk']::text[]) t loop
        node := jsonb_set(node, array[group_key, space_key, 'Average Sort Space Used'], '"NN"', false);
        node := jsonb_set(node, array[group_key, space_key, 'Peak Sort Space Used'], '"NN"', false);
      end loop;
    end loop;
    nodes := nodes || node;
  end loop;
  return nodes;
end;
$$;


ALTER FUNCTION public.explain_analyze_inc_sort_nodes_without_memory(query text) OWNER TO ashutoshpg;

--
-- Name: explain_analyze_without_memory(text); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.explain_analyze_without_memory(query text) RETURNS TABLE(out_line text)
    LANGUAGE plpgsql
    AS $$
declare
  line text;
begin
  for line in
    execute 'explain (analyze, costs off, summary off, timing off) ' || query
  loop
    out_line := regexp_replace(line, '\d+kB', 'NNkB', 'g');
    return next;
  end loop;
end;
$$;


ALTER FUNCTION public.explain_analyze_without_memory(query text) OWNER TO ashutoshpg;

--
-- Name: explain_filter(text); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.explain_filter(text) RETURNS SETOF text
    LANGUAGE plpgsql
    AS $_$
declare
    ln text;
begin
    for ln in execute $1
    loop
        -- Replace any numeric word with just 'N'
        ln := regexp_replace(ln, '-?\m\d+\M', 'N', 'g');
        -- In sort output, the above won't match units-suffixed numbers
        ln := regexp_replace(ln, '\m\d+kB', 'NkB', 'g');
        -- Ignore text-mode buffers output because it varies depending
        -- on the system state
        CONTINUE WHEN (ln ~ ' +Buffers: .*');
        -- Ignore text-mode "Planning:" line because whether it's output
        -- varies depending on the system state
        CONTINUE WHEN (ln = 'Planning:');
        return next ln;
    end loop;
end;
$_$;


ALTER FUNCTION public.explain_filter(text) OWNER TO ashutoshpg;

--
-- Name: explain_filter_to_json(text); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.explain_filter_to_json(text) RETURNS jsonb
    LANGUAGE plpgsql
    AS $_$
declare
    data text := '';
    ln text;
begin
    for ln in execute $1
    loop
        -- Replace any numeric word with just '0'
        ln := regexp_replace(ln, '\m\d+\M', '0', 'g');
        data := data || ln;
    end loop;
    return data::jsonb;
end;
$_$;


ALTER FUNCTION public.explain_filter_to_json(text) OWNER TO ashutoshpg;

--
-- Name: explain_memoize(text, boolean); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.explain_memoize(query text, hide_hitmiss boolean) RETURNS SETOF text
    LANGUAGE plpgsql
    AS $$
declare
    ln text;
begin
    for ln in
        execute format('explain (analyze, costs off, summary off, timing off) %s',
            query)
    loop
        if hide_hitmiss = true then
                ln := regexp_replace(ln, 'Hits: 0', 'Hits: Zero');
                ln := regexp_replace(ln, 'Hits: \d+', 'Hits: N');
                ln := regexp_replace(ln, 'Misses: 0', 'Misses: Zero');
                ln := regexp_replace(ln, 'Misses: \d+', 'Misses: N');
        end if;
        ln := regexp_replace(ln, 'Evictions: 0', 'Evictions: Zero');
        ln := regexp_replace(ln, 'Evictions: \d+', 'Evictions: N');
        ln := regexp_replace(ln, 'Memory Usage: \d+', 'Memory Usage: N');
	ln := regexp_replace(ln, 'Heap Fetches: \d+', 'Heap Fetches: N');
	ln := regexp_replace(ln, 'loops=\d+', 'loops=N');
        return next ln;
    end loop;
end;
$$;


ALTER FUNCTION public.explain_memoize(query text, hide_hitmiss boolean) OWNER TO ashutoshpg;

--
-- Name: explain_parallel_append(text); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.explain_parallel_append(text) RETURNS SETOF text
    LANGUAGE plpgsql
    AS $_$
declare
    ln text;
begin
    for ln in
        execute format('explain (analyze, costs off, summary off, timing off) %s',
            $1)
    loop
        ln := regexp_replace(ln, 'Workers Launched: \d+', 'Workers Launched: N');
        ln := regexp_replace(ln, 'actual rows=\d+ loops=\d+', 'actual rows=N loops=N');
        ln := regexp_replace(ln, 'Rows Removed by Filter: \d+', 'Rows Removed by Filter: N');
        return next ln;
    end loop;
end;
$_$;


ALTER FUNCTION public.explain_parallel_append(text) OWNER TO ashutoshpg;

--
-- Name: explain_query_json(text); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.explain_query_json(query_sql text) RETURNS TABLE(explain_line json)
    LANGUAGE plpgsql
    AS $$
begin
  set enable_seqscan = off;
  set enable_bitmapscan = on;
  return query execute 'EXPLAIN (ANALYZE, FORMAT json) ' || query_sql;
end;
$$;


ALTER FUNCTION public.explain_query_json(query_sql text) OWNER TO ashutoshpg;

--
-- Name: int8_tbl; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.int8_tbl (
    q1 bigint,
    q2 bigint
);


ALTER TABLE public.int8_tbl OWNER TO ashutoshpg;

--
-- Name: extractq2(public.int8_tbl); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.extractq2(t public.int8_tbl) RETURNS bigint
    LANGUAGE sql IMMUTABLE
    AS $$
  select t.q2
$$;


ALTER FUNCTION public.extractq2(t public.int8_tbl) OWNER TO ashutoshpg;

--
-- Name: extractq2_2(public.int8_tbl); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.extractq2_2(t public.int8_tbl) RETURNS TABLE(ret1 bigint)
    LANGUAGE sql IMMUTABLE
    AS $$
  select extractq2(t) offset 0
$$;


ALTER FUNCTION public.extractq2_2(t public.int8_tbl) OWNER TO ashutoshpg;

--
-- Name: extractq2_2_opt(public.int8_tbl); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.extractq2_2_opt(t public.int8_tbl) RETURNS TABLE(ret1 bigint)
    LANGUAGE sql IMMUTABLE
    AS $$
  select extractq2(t)
$$;


ALTER FUNCTION public.extractq2_2_opt(t public.int8_tbl) OWNER TO ashutoshpg;

--
-- Name: f1_times_10(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.f1_times_10() RETURNS trigger
    LANGUAGE plpgsql
    AS $$ begin new.f1 := new.f1 * 10; return new; end $$;


ALTER FUNCTION public.f1_times_10() OWNER TO ashutoshpg;

--
-- Name: f_leak(text); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.f_leak(text) RETURNS boolean
    LANGUAGE plpgsql COST 1e-07
    AS $_$BEGIN RAISE NOTICE 'f_leak => %', $1; RETURN true; END$_$;


ALTER FUNCTION public.f_leak(text) OWNER TO ashutoshpg;

--
-- Name: ffnp(integer[]); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.ffnp(integer[]) RETURNS integer[]
    LANGUAGE sql
    AS $_$select $1$_$;


ALTER FUNCTION public.ffnp(integer[]) OWNER TO ashutoshpg;

--
-- Name: ffp(anyarray); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.ffp(anyarray) RETURNS anyarray
    LANGUAGE sql
    AS $_$select $1$_$;


ALTER FUNCTION public.ffp(anyarray) OWNER TO ashutoshpg;

--
-- Name: fipshash(bytea); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.fipshash(bytea) RETURNS text
    LANGUAGE sql IMMUTABLE STRICT LEAKPROOF PARALLEL SAFE
    RETURN substr(encode(sha256($1), 'hex'::text), 1, 32);


ALTER FUNCTION public.fipshash(bytea) OWNER TO ashutoshpg;

--
-- Name: fipshash(text); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.fipshash(text) RETURNS text
    LANGUAGE sql IMMUTABLE STRICT LEAKPROOF PARALLEL SAFE
    RETURN substr(encode(sha256(($1)::bytea), 'hex'::text), 1, 32);


ALTER FUNCTION public.fipshash(text) OWNER TO ashutoshpg;

--
-- Name: first_el(anyarray); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.first_el(anyarray) RETURNS anyelement
    LANGUAGE sql IMMUTABLE STRICT
    AS $_$select $1[1]$_$;


ALTER FUNCTION public.first_el(anyarray) OWNER TO ashutoshpg;

--
-- Name: first_el_transfn(anyarray, anyelement); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.first_el_transfn(anyarray, anyelement) RETURNS anyarray
    LANGUAGE sql IMMUTABLE
    AS $_$select $1 || $2$_$;


ALTER FUNCTION public.first_el_transfn(anyarray, anyelement) OWNER TO ashutoshpg;

--
-- Name: float8mi_int(double precision, double precision); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.float8mi_int(double precision, double precision) RETURNS integer
    LANGUAGE sql
    AS $_$ SELECT CAST($1 - $2 AS INT); $_$;


ALTER FUNCTION public.float8mi_int(double precision, double precision) OWNER TO ashutoshpg;

--
-- Name: float8mi_n(double precision, double precision); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.float8mi_n(double precision, double precision) RETURNS double precision
    LANGUAGE sql
    AS $_$ SELECT $1 - $2; $_$;


ALTER FUNCTION public.float8mi_n(double precision, double precision) OWNER TO ashutoshpg;

--
-- Name: func_with_bad_set(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.func_with_bad_set() RETURNS integer
    LANGUAGE sql
    SET default_text_search_config TO 'no_such_config'
    AS $$ select 1 $$;


ALTER FUNCTION public.func_with_bad_set() OWNER TO ashutoshpg;

--
-- Name: func_with_set_params(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.func_with_set_params() RETURNS integer
    LANGUAGE sql IMMUTABLE STRICT
    SET search_path TO 'pg_catalog'
    SET extra_float_digits TO '2'
    SET work_mem TO '4MB'
    SET "DateStyle" TO 'iso, mdy'
    SET local_preload_libraries TO 'Mixed/Case', 'c:/''a"/path', '', '0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789'
    AS $$select 1;$$;


ALTER FUNCTION public.func_with_set_params() OWNER TO ashutoshpg;

--
-- Name: partitioned_table; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.partitioned_table (
    a integer,
    b text
)
PARTITION BY LIST (a);


ALTER TABLE public.partitioned_table OWNER TO ashutoshpg;

--
-- Name: get_from_partitioned_table(integer); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.get_from_partitioned_table(integer) RETURNS public.partitioned_table
    LANGUAGE plpgsql
    AS $_$
DECLARE
    a_val partitioned_table.a%TYPE;
    result partitioned_table%ROWTYPE;
BEGIN
    a_val := $1;
    SELECT * INTO result FROM partitioned_table WHERE a = a_val;
    RETURN result;
END; $_$;


ALTER FUNCTION public.get_from_partitioned_table(integer) OWNER TO ashutoshpg;

--
-- Name: gstest_data(integer); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.gstest_data(v integer, OUT a integer, OUT b integer) RETURNS SETOF record
    LANGUAGE plpgsql
    AS $$
    begin
      return query select v, i from generate_series(1,3) i;
    end;
  $$;


ALTER FUNCTION public.gstest_data(v integer, OUT a integer, OUT b integer) OWNER TO ashutoshpg;

--
-- Name: person; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.person (
    name text,
    age integer,
    location point
);


ALTER TABLE public.person OWNER TO ashutoshpg;

--
-- Name: hobbies(public.person); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.hobbies(public.person) RETURNS SETOF public.hobbies_r
    LANGUAGE sql
    AS $_$select * from hobbies_r where person = $1.name$_$;


ALTER FUNCTION public.hobbies(public.person) OWNER TO ashutoshpg;

--
-- Name: hobbies_by_name(text); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.hobbies_by_name(text) RETURNS text
    LANGUAGE sql
    AS $_$select person from hobbies_r where name = $1$_$;


ALTER FUNCTION public.hobbies_by_name(text) OWNER TO ashutoshpg;

--
-- Name: hobby_construct(text, text); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.hobby_construct(text, text) RETURNS public.hobbies_r
    LANGUAGE sql
    AS $_$select $1 as name, $2 as hobby$_$;


ALTER FUNCTION public.hobby_construct(text, text) OWNER TO ashutoshpg;

--
-- Name: hobby_construct_named(text, text); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.hobby_construct_named(name text, hobby text) RETURNS public.hobbies_r
    LANGUAGE sql
    AS $$select name, hobby$$;


ALTER FUNCTION public.hobby_construct_named(name text, hobby text) OWNER TO ashutoshpg;

--
-- Name: infinite_recurse(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.infinite_recurse() RETURNS integer
    LANGUAGE sql
    AS $$select infinite_recurse()$$;


ALTER FUNCTION public.infinite_recurse() OWNER TO ashutoshpg;

--
-- Name: inoutparam_succeed(anyrange); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.inoutparam_succeed(OUT i anyelement, INOUT r anyrange) RETURNS record
    LANGUAGE sql
    AS $_$ select upper($1), $1 $_$;


ALTER FUNCTION public.inoutparam_succeed(OUT i anyelement, INOUT r anyrange) OWNER TO ashutoshpg;

--
-- Name: insert_tt(text); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.insert_tt(text) RETURNS integer
    LANGUAGE sql
    AS $_$ insert into tt(data) values($1),($1||$1) returning f1 $_$;


ALTER FUNCTION public.insert_tt(text) OWNER TO ashutoshpg;

--
-- Name: insert_tt2(text, text); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.insert_tt2(text, text) RETURNS SETOF integer
    LANGUAGE sql
    AS $_$ insert into tt(data) values($1),($2) returning f1 $_$;


ALTER FUNCTION public.insert_tt2(text, text) OWNER TO ashutoshpg;

--
-- Name: int8alias1cmp(bigint, public.int8alias1); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.int8alias1cmp(bigint, public.int8alias1) RETURNS integer
    LANGUAGE internal IMMUTABLE STRICT
    AS $$btint8cmp$$;


ALTER FUNCTION public.int8alias1cmp(bigint, public.int8alias1) OWNER TO ashutoshpg;

--
-- Name: int8alias1eq(bigint, public.int8alias1); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.int8alias1eq(bigint, public.int8alias1) RETURNS boolean
    LANGUAGE internal IMMUTABLE STRICT
    AS $$int8eq$$;


ALTER FUNCTION public.int8alias1eq(bigint, public.int8alias1) OWNER TO ashutoshpg;

--
-- Name: int8alias1eq(public.int8alias1, public.int8alias1); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.int8alias1eq(public.int8alias1, public.int8alias1) RETURNS boolean
    LANGUAGE internal IMMUTABLE STRICT
    AS $$int8eq$$;


ALTER FUNCTION public.int8alias1eq(public.int8alias1, public.int8alias1) OWNER TO ashutoshpg;

--
-- Name: int8alias1eq(public.int8alias1, public.int8alias2); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.int8alias1eq(public.int8alias1, public.int8alias2) RETURNS boolean
    LANGUAGE internal IMMUTABLE STRICT
    AS $$int8eq$$;


ALTER FUNCTION public.int8alias1eq(public.int8alias1, public.int8alias2) OWNER TO ashutoshpg;

--
-- Name: int8alias1lt(public.int8alias1, public.int8alias1); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.int8alias1lt(public.int8alias1, public.int8alias1) RETURNS boolean
    LANGUAGE internal IMMUTABLE STRICT
    AS $$int8lt$$;


ALTER FUNCTION public.int8alias1lt(public.int8alias1, public.int8alias1) OWNER TO ashutoshpg;

--
-- Name: int8alias2eq(public.int8alias2, public.int8alias2); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.int8alias2eq(public.int8alias2, public.int8alias2) RETURNS boolean
    LANGUAGE internal IMMUTABLE STRICT
    AS $$int8eq$$;


ALTER FUNCTION public.int8alias2eq(public.int8alias2, public.int8alias2) OWNER TO ashutoshpg;

--
-- Name: interpt_pp(path, path); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.interpt_pp(path, path) RETURNS point
    LANGUAGE c STRICT
    AS '/home/ashutoshpg/work/units/pg_dump_test/build/dev/src/test/regress/regress.so', 'interpt_pp';


ALTER FUNCTION public.interpt_pp(path, path) OWNER TO ashutoshpg;

--
-- Name: ks_test_normal_random(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.ks_test_normal_random() RETURNS boolean
    LANGUAGE plpgsql
    AS $$
DECLARE
  n int := 1000;        -- Number of samples
  c float8 := 1.94947;  -- Critical value for 99.9% confidence
  ok boolean;
BEGIN
  ok := (
    WITH samples AS (
      SELECT random_normal() r FROM generate_series(1, n) ORDER BY 1
    ), indexed_samples AS (
      SELECT (row_number() OVER())-1.0 i, r FROM samples
    )
    SELECT max(abs((1+erf(r/sqrt(2)))/2 - i/n)) < c / sqrt(n)
    FROM indexed_samples
  );
  RETURN ok;
END
$$;


ALTER FUNCTION public.ks_test_normal_random() OWNER TO ashutoshpg;

--
-- Name: ks_test_uniform_random(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.ks_test_uniform_random() RETURNS boolean
    LANGUAGE plpgsql
    AS $$
DECLARE
  n int := 1000;        -- Number of samples
  c float8 := 1.94947;  -- Critical value for 99.9% confidence
  ok boolean;
BEGIN
  ok := (
    WITH samples AS (
      SELECT random() r FROM generate_series(1, n) ORDER BY 1
    ), indexed_samples AS (
      SELECT (row_number() OVER())-1.0 i, r FROM samples
    )
    SELECT max(abs(i/n-r)) < c / sqrt(n) FROM indexed_samples
  );
  RETURN ok;
END
$$;


ALTER FUNCTION public.ks_test_uniform_random() OWNER TO ashutoshpg;

--
-- Name: ks_test_uniform_random_bigint_in_range(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.ks_test_uniform_random_bigint_in_range() RETURNS boolean
    LANGUAGE plpgsql
    AS $$
DECLARE
  n int := 1000;        -- Number of samples
  c float8 := 1.94947;  -- Critical value for 99.9% confidence
  ok boolean;
BEGIN
  ok := (
    WITH samples AS (
      SELECT random(0, 999999999999) / 1000000000000.0 r FROM generate_series(1, n) ORDER BY 1
    ), indexed_samples AS (
      SELECT (row_number() OVER())-1.0 i, r FROM samples
    )
    SELECT max(abs(i/n-r)) < c / sqrt(n) FROM indexed_samples
  );
  RETURN ok;
END
$$;


ALTER FUNCTION public.ks_test_uniform_random_bigint_in_range() OWNER TO ashutoshpg;

--
-- Name: ks_test_uniform_random_int_in_range(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.ks_test_uniform_random_int_in_range() RETURNS boolean
    LANGUAGE plpgsql
    AS $$
DECLARE
  n int := 1000;        -- Number of samples
  c float8 := 1.94947;  -- Critical value for 99.9% confidence
  ok boolean;
BEGIN
  ok := (
    WITH samples AS (
      SELECT random(0, 999999) / 1000000.0 r FROM generate_series(1, n) ORDER BY 1
    ), indexed_samples AS (
      SELECT (row_number() OVER())-1.0 i, r FROM samples
    )
    SELECT max(abs(i/n-r)) < c / sqrt(n) FROM indexed_samples
  );
  RETURN ok;
END
$$;


ALTER FUNCTION public.ks_test_uniform_random_int_in_range() OWNER TO ashutoshpg;

--
-- Name: ks_test_uniform_random_numeric_in_range(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.ks_test_uniform_random_numeric_in_range() RETURNS boolean
    LANGUAGE plpgsql
    AS $$
DECLARE
  n int := 1000;        -- Number of samples
  c float8 := 1.94947;  -- Critical value for 99.9% confidence
  ok boolean;
BEGIN
  ok := (
    WITH samples AS (
      SELECT random(0, 0.999999) r FROM generate_series(1, n) ORDER BY 1
    ), indexed_samples AS (
      SELECT (row_number() OVER())-1.0 i, r FROM samples
    )
    SELECT max(abs(i/n-r)) < c / sqrt(n) FROM indexed_samples
  );
  RETURN ok;
END
$$;


ALTER FUNCTION public.ks_test_uniform_random_numeric_in_range() OWNER TO ashutoshpg;

--
-- Name: large_val(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.large_val() RETURNS text
    LANGUAGE sql
    AS $$select array_agg(fipshash(g::text))::text from generate_series(1, 256) g$$;


ALTER FUNCTION public.large_val() OWNER TO ashutoshpg;

--
-- Name: least_accum(anyelement, anyarray); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.least_accum(anyelement, VARIADIC anyarray) RETURNS anyelement
    LANGUAGE sql
    AS $_$select least($1, min($2[i])) from generate_subscripts($2,1) g(i)$_$;


ALTER FUNCTION public.least_accum(anyelement, VARIADIC anyarray) OWNER TO ashutoshpg;

--
-- Name: list_partitioned_table(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.list_partitioned_table() RETURNS SETOF integer
    LANGUAGE plpgsql
    AS $$
DECLARE
    row public.partitioned_table%ROWTYPE;
    a_val public.partitioned_table.a%TYPE;
BEGIN
    FOR row IN SELECT * FROM public.partitioned_table ORDER BY a LOOP
        a_val := row.a;
        RETURN NEXT a_val;
    END LOOP;
    RETURN;
END; $$;


ALTER FUNCTION public.list_partitioned_table() OWNER TO ashutoshpg;

--
-- Name: logging_minvfunc_nonstrict(text, anyelement); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.logging_minvfunc_nonstrict(text, anyelement) RETURNS text
    LANGUAGE sql IMMUTABLE
    AS $_$ SELECT $1 || '-' || quote_nullable($2) $_$;


ALTER FUNCTION public.logging_minvfunc_nonstrict(text, anyelement) OWNER TO ashutoshpg;

--
-- Name: logging_minvfunc_strict(text, anyelement); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.logging_minvfunc_strict(text, anyelement) RETURNS text
    LANGUAGE sql IMMUTABLE STRICT
    AS $_$ SELECT $1 || '-' || quote_nullable($2) $_$;


ALTER FUNCTION public.logging_minvfunc_strict(text, anyelement) OWNER TO ashutoshpg;

--
-- Name: logging_msfunc_nonstrict(text, anyelement); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.logging_msfunc_nonstrict(text, anyelement) RETURNS text
    LANGUAGE sql IMMUTABLE
    AS $_$ SELECT COALESCE($1, '') || '+' || quote_nullable($2) $_$;


ALTER FUNCTION public.logging_msfunc_nonstrict(text, anyelement) OWNER TO ashutoshpg;

--
-- Name: logging_msfunc_strict(text, anyelement); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.logging_msfunc_strict(text, anyelement) RETURNS text
    LANGUAGE sql IMMUTABLE STRICT
    AS $_$ SELECT $1 || '+' || quote_nullable($2) $_$;


ALTER FUNCTION public.logging_msfunc_strict(text, anyelement) OWNER TO ashutoshpg;

--
-- Name: logging_sfunc_nonstrict(text, anyelement); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.logging_sfunc_nonstrict(text, anyelement) RETURNS text
    LANGUAGE sql IMMUTABLE
    AS $_$ SELECT COALESCE($1, '') || '*' || quote_nullable($2) $_$;


ALTER FUNCTION public.logging_sfunc_nonstrict(text, anyelement) OWNER TO ashutoshpg;

--
-- Name: logging_sfunc_strict(text, anyelement); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.logging_sfunc_strict(text, anyelement) RETURNS text
    LANGUAGE sql IMMUTABLE STRICT
    AS $_$ SELECT $1 || '*' || quote_nullable($2) $_$;


ALTER FUNCTION public.logging_sfunc_strict(text, anyelement) OWNER TO ashutoshpg;

--
-- Name: make_table(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.make_table() RETURNS void
    LANGUAGE sql
    AS $$
  CREATE TABLE created_table AS SELECT * FROM int8_tbl;
$$;


ALTER FUNCTION public.make_table() OWNER TO ashutoshpg;

--
-- Name: make_tuple_indirect(record); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.make_tuple_indirect(record) RETURNS record
    LANGUAGE c STRICT
    AS '/home/ashutoshpg/work/units/pg_dump_test/build/dev/src/test/regress/regress.so', 'make_tuple_indirect';


ALTER FUNCTION public.make_tuple_indirect(record) OWNER TO ashutoshpg;

--
-- Name: max_xacttest(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.max_xacttest() RETURNS smallint
    LANGUAGE plpgsql
    AS $$begin return max(a) from xacttest; end$$;


ALTER FUNCTION public.max_xacttest() OWNER TO ashutoshpg;

--
-- Name: mlparted5abrtrig_func(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.mlparted5abrtrig_func() RETURNS trigger
    LANGUAGE plpgsql
    AS $$ begin new.c = 'b'; return new; end; $$;


ALTER FUNCTION public.mlparted5abrtrig_func() OWNER TO ashutoshpg;

--
-- Name: mr_inoutparam_succeed(anymultirange); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.mr_inoutparam_succeed(OUT i anyelement, INOUT r anymultirange) RETURNS record
    LANGUAGE sql
    AS $_$ select upper($1), $1 $_$;


ALTER FUNCTION public.mr_inoutparam_succeed(OUT i anyelement, INOUT r anymultirange) OWNER TO ashutoshpg;

--
-- Name: mr_outparam_succeed(anymultirange); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.mr_outparam_succeed(i anymultirange, OUT r anymultirange, OUT t text) RETURNS record
    LANGUAGE sql
    AS $_$ select $1, 'foo'::text $_$;


ALTER FUNCTION public.mr_outparam_succeed(i anymultirange, OUT r anymultirange, OUT t text) OWNER TO ashutoshpg;

--
-- Name: mr_outparam_succeed2(anymultirange); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.mr_outparam_succeed2(i anymultirange, OUT r anyarray, OUT t text) RETURNS record
    LANGUAGE sql
    AS $_$ select ARRAY[upper($1)], 'foo'::text $_$;


ALTER FUNCTION public.mr_outparam_succeed2(i anymultirange, OUT r anyarray, OUT t text) OWNER TO ashutoshpg;

--
-- Name: mr_outparam_succeed3(anymultirange); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.mr_outparam_succeed3(i anymultirange, OUT r anyrange, OUT t text) RETURNS record
    LANGUAGE sql
    AS $_$ select range_merge($1), 'foo'::text $_$;


ALTER FUNCTION public.mr_outparam_succeed3(i anymultirange, OUT r anyrange, OUT t text) OWNER TO ashutoshpg;

--
-- Name: mr_outparam_succeed4(anyrange); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.mr_outparam_succeed4(i anyrange, OUT r anymultirange, OUT t text) RETURNS record
    LANGUAGE sql
    AS $_$ select multirange($1), 'foo'::text $_$;


ALTER FUNCTION public.mr_outparam_succeed4(i anyrange, OUT r anymultirange, OUT t text) OWNER TO ashutoshpg;

--
-- Name: mr_polymorphic(anyrange); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.mr_polymorphic(i anyrange) RETURNS anymultirange
    LANGUAGE plpgsql
    AS $_$ begin return multirange($1); end; $_$;


ALTER FUNCTION public.mr_polymorphic(i anyrange) OWNER TO ashutoshpg;

--
-- Name: mr_table_succeed(anyelement, anymultirange); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.mr_table_succeed(i anyelement, r anymultirange) RETURNS TABLE(i anyelement, r anymultirange)
    LANGUAGE sql
    AS $_$ select $1, $2 $_$;


ALTER FUNCTION public.mr_table_succeed(i anyelement, r anymultirange) OWNER TO ashutoshpg;

--
-- Name: multi_datum_use(integer); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.multi_datum_use(p1 integer) RETURNS boolean
    LANGUAGE plpgsql
    AS $_$
declare
  x int;
  y int;
begin
  select into x,y unique1/p1, unique1/$1 from tenk1 group by unique1/p1;
  return x = y;
end$_$;


ALTER FUNCTION public.multi_datum_use(p1 integer) OWNER TO ashutoshpg;

--
-- Name: multirangetypes_sql(anymultirange, anyarray); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.multirangetypes_sql(q anymultirange, b anyarray, OUT c anyelement) RETURNS anyelement
    LANGUAGE sql
    AS $_$ select upper($1) + $2[1] $_$;


ALTER FUNCTION public.multirangetypes_sql(q anymultirange, b anyarray, OUT c anyelement) OWNER TO ashutoshpg;

--
-- Name: test_support_func(internal); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.test_support_func(internal) RETURNS internal
    LANGUAGE c STRICT
    AS '/home/ashutoshpg/work/units/pg_dump_test/build/dev/src/test/regress/regress.so', 'test_support_func';


ALTER FUNCTION public.test_support_func(internal) OWNER TO ashutoshpg;

--
-- Name: my_gen_series(integer, integer); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.my_gen_series(integer, integer) RETURNS SETOF integer
    LANGUAGE internal IMMUTABLE STRICT SUPPORT public.test_support_func PARALLEL SAFE
    AS $$generate_series_int4$$;


ALTER FUNCTION public.my_gen_series(integer, integer) OWNER TO ashutoshpg;

--
-- Name: my_int_eq(integer, integer); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.my_int_eq(integer, integer) RETURNS boolean
    LANGUAGE internal IMMUTABLE STRICT SUPPORT public.test_support_func PARALLEL SAFE
    AS $$int4eq$$;


ALTER FUNCTION public.my_int_eq(integer, integer) OWNER TO ashutoshpg;

--
-- Name: myfunc(integer); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.myfunc(integer) RETURNS text
    LANGUAGE plpgsql
    SET work_mem TO '1MB'
    AS $_$
begin
  set work_mem = '2MB';
  perform 1/$1;
  return current_setting('work_mem');
end $_$;


ALTER FUNCTION public.myfunc(integer) OWNER TO ashutoshpg;

--
-- Name: myleast(anyarray); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.myleast(VARIADIC anyarray) RETURNS anyelement
    LANGUAGE sql IMMUTABLE STRICT
    AS $_$
  select min($1[i]) from generate_subscripts($1,1) g(i)
$_$;


ALTER FUNCTION public.myleast(VARIADIC anyarray) OWNER TO ashutoshpg;

--
-- Name: namedparmcursor_test1(integer, integer); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.namedparmcursor_test1(integer, integer) RETURNS boolean
    LANGUAGE plpgsql
    AS $_$
declare
    c1 cursor (param1 int, param12 int) for select * from rc_test where a > param1 and b > param12;
    nonsense record;
begin
    open c1(param12 := $2, param1 := $1);
    fetch c1 into nonsense;
    close c1;
    if found then
        return true;
    else
        return false;
    end if;
end
$_$;


ALTER FUNCTION public.namedparmcursor_test1(integer, integer) OWNER TO ashutoshpg;

--
-- Name: namedparmcursor_test2(integer, integer); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.namedparmcursor_test2(integer, integer) RETURNS boolean
    LANGUAGE plpgsql
    AS $_$
declare
    c1 cursor (param1 int, param2 int) for select * from rc_test where a > param1 and b > param2;
    nonsense record;
begin
    open c1(param1 := $1, $2);
    fetch c1 into nonsense;
    close c1;
    if found then
        return true;
    else
        return false;
    end if;
end
$_$;


ALTER FUNCTION public.namedparmcursor_test2(integer, integer) OWNER TO ashutoshpg;

--
-- Name: namedparmcursor_test7(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.namedparmcursor_test7() RETURNS void
    LANGUAGE plpgsql
    AS $$
declare
  c1 cursor (p1 int, p2 int) for
    select * from tenk1 where thousand = p1 and tenthous = p2;
begin
  open c1 (p2 := 77, p1 := 42/0);
end $$;


ALTER FUNCTION public.namedparmcursor_test7() OWNER TO ashutoshpg;

--
-- Name: namedparmcursor_test8(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.namedparmcursor_test8() RETURNS integer
    LANGUAGE plpgsql
    AS $$
declare
  c1 cursor (p1 int, p2 int) for
    select count(*) from tenk1 where thousand = p1 and tenthous = p2;
  n int4;
begin
  open c1 (77 -- test
  , 42);
  fetch c1 into n;
  return n;
end $$;


ALTER FUNCTION public.namedparmcursor_test8() OWNER TO ashutoshpg;

--
-- Name: namedparmcursor_test9(integer); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.namedparmcursor_test9(p1 integer) RETURNS integer
    LANGUAGE plpgsql
    AS $$
declare
  c1 cursor (p1 int, p2 int, debug int) for
    select count(*) from tenk1 where thousand = p1 and tenthous = p2
      and four = debug;
  p2 int4 := 1006;
  n int4;
begin
  open c1 (p1 := p1, p2 := p2, debug := 2);
  fetch c1 into n;
  return n;
end $$;


ALTER FUNCTION public.namedparmcursor_test9(p1 integer) OWNER TO ashutoshpg;

--
-- Name: namelen(public.person_type); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.namelen(public.person_type) RETURNS integer
    LANGUAGE sql
    AS $_$ SELECT length($1.name) $_$;


ALTER FUNCTION public.namelen(public.person_type) OWNER TO ashutoshpg;

--
-- Name: no_op_trig_fn(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.no_op_trig_fn() RETURNS trigger
    LANGUAGE plpgsql
    AS $$begin RETURN NULL; end$$;


ALTER FUNCTION public.no_op_trig_fn() OWNER TO ashutoshpg;

--
-- Name: non_strict(text); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.non_strict(text) RETURNS text
    LANGUAGE sql STRICT
    AS $_$select coalesce($1, 'got passed a null');$_$;


ALTER FUNCTION public.non_strict(text) OWNER TO ashutoshpg;

--
-- Name: noticetrigger(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.noticetrigger() RETURNS trigger
    LANGUAGE plpgsql
    AS $$
begin
  raise notice 'noticetrigger % %', new.f1, new.data;
  return null;
end $$;


ALTER FUNCTION public.noticetrigger() OWNER TO ashutoshpg;

--
-- Name: nth_value_def(anyelement, integer); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.nth_value_def(val anyelement, n integer DEFAULT 1) RETURNS anyelement
    LANGUAGE internal WINDOW IMMUTABLE STRICT
    AS $$window_nth_value$$;


ALTER FUNCTION public.nth_value_def(val anyelement, n integer) OWNER TO ashutoshpg;

--
-- Name: outparam2_succeed(anyrange); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.outparam2_succeed(r anyrange, OUT lu anyarray, OUT ul anyarray) RETURNS record
    LANGUAGE sql
    AS $_$ select array[lower($1), upper($1)], array[upper($1), lower($1)] $_$;


ALTER FUNCTION public.outparam2_succeed(r anyrange, OUT lu anyarray, OUT ul anyarray) OWNER TO ashutoshpg;

--
-- Name: outparam_succeed(anyrange); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.outparam_succeed(i anyrange, OUT r anyrange, OUT t text) RETURNS record
    LANGUAGE sql
    AS $_$ select $1, 'foo'::text $_$;


ALTER FUNCTION public.outparam_succeed(i anyrange, OUT r anyrange, OUT t text) OWNER TO ashutoshpg;

--
-- Name: outparam_succeed2(anyrange); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.outparam_succeed2(i anyrange, OUT r anyarray, OUT t text) RETURNS record
    LANGUAGE sql
    AS $_$ select ARRAY[upper($1)], 'foo'::text $_$;


ALTER FUNCTION public.outparam_succeed2(i anyrange, OUT r anyarray, OUT t text) OWNER TO ashutoshpg;

--
-- Name: emp; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.emp (
    salary integer,
    manager name
)
INHERITS (public.person);


ALTER TABLE public.emp OWNER TO ashutoshpg;

--
-- Name: overpaid(public.emp); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.overpaid(public.emp) RETURNS boolean
    LANGUAGE c STRICT
    AS '/home/ashutoshpg/work/units/pg_dump_test/build/dev/src/test/regress/regress.so', 'overpaid';


ALTER FUNCTION public.overpaid(public.emp) OWNER TO ashutoshpg;

--
-- Name: part_hashint4_noop(integer, bigint); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.part_hashint4_noop(value integer, seed bigint) RETURNS bigint
    LANGUAGE sql IMMUTABLE STRICT PARALLEL SAFE
    AS $$
    select value + seed;
    $$;


ALTER FUNCTION public.part_hashint4_noop(value integer, seed bigint) OWNER TO ashutoshpg;

--
-- Name: part_hashtext_length(text, bigint); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.part_hashtext_length(value text, seed bigint) RETURNS bigint
    LANGUAGE sql IMMUTABLE STRICT PARALLEL SAFE
    AS $$
    select length(coalesce(value, ''))::int8
    $$;


ALTER FUNCTION public.part_hashtext_length(value text, seed bigint) OWNER TO ashutoshpg;

--
-- Name: part_ins_func(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.part_ins_func() RETURNS trigger
    LANGUAGE plpgsql
    AS $$
begin
  return new;
end;
$$;


ALTER FUNCTION public.part_ins_func() OWNER TO ashutoshpg;

--
-- Name: parted_trigfunc2(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.parted_trigfunc2() RETURNS trigger
    LANGUAGE plpgsql
    AS $$
begin
  new.a = new.a + 1;
  return new;
end;
$$;


ALTER FUNCTION public.parted_trigfunc2() OWNER TO ashutoshpg;

--
-- Name: perform_simple_func(integer); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.perform_simple_func(integer) RETURNS boolean
    LANGUAGE plpgsql
    AS $_$
BEGIN
	IF $1 < 20 THEN
		INSERT INTO perform_test VALUES ($1, $1 + 10);
		RETURN TRUE;
	ELSE
		RETURN FALSE;
	END IF;
END;$_$;


ALTER FUNCTION public.perform_simple_func(integer) OWNER TO ashutoshpg;

--
-- Name: perform_test_func(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.perform_test_func() RETURNS void
    LANGUAGE plpgsql
    AS $$
BEGIN
	IF FOUND then
		INSERT INTO perform_test VALUES (100, 100);
	END IF;

	PERFORM perform_simple_func(5);

	IF FOUND then
		INSERT INTO perform_test VALUES (100, 100);
	END IF;

	PERFORM perform_simple_func(50);

	IF FOUND then
		INSERT INTO perform_test VALUES (100, 100);
	END IF;

	RETURN;
END;$$;


ALTER FUNCTION public.perform_test_func() OWNER TO ashutoshpg;

--
-- Name: plusone(integer); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.plusone(a integer) RETURNS integer
    LANGUAGE sql
    AS $$ SELECT a+1; $$;


ALTER FUNCTION public.plusone(a integer) OWNER TO ashutoshpg;

--
-- Name: pslot_backlink_view(character); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.pslot_backlink_view(character) RETURNS text
    LANGUAGE plpgsql
    AS $_$
<<outer>>
declare
    rec		record;
    bltype	char(2);
    retval	text;
begin
    select into rec * from PSlot where slotname = $1;
    if not found then
        return '';
    end if;
    if rec.backlink = '' then
        return '-';
    end if;
    bltype := substr(rec.backlink, 1, 2);
    if bltype = 'PL' then
        declare
	    rec		record;
	begin
	    select into rec * from PLine where slotname = "outer".rec.backlink;
	    retval := 'Phone line ' || trim(rec.phonenumber);
	    if rec.comment != '' then
	        retval := retval || ' (';
		retval := retval || rec.comment;
		retval := retval || ')';
	    end if;
	    return retval;
	end;
    end if;
    if bltype = 'WS' then
        select into rec * from WSlot where slotname = rec.backlink;
	retval := trim(rec.slotname) || ' in room ';
	retval := retval || trim(rec.roomno);
	retval := retval || ' -> ';
	return retval || wslot_slotlink_view(rec.slotname);
    end if;
    return rec.backlink;
end;
$_$;


ALTER FUNCTION public.pslot_backlink_view(character) OWNER TO ashutoshpg;

--
-- Name: pslot_slotlink_view(character); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.pslot_slotlink_view(character) RETURNS text
    LANGUAGE plpgsql
    AS $_$
declare
    psrec	record;
    sltype	char(2);
    retval	text;
begin
    select into psrec * from PSlot where slotname = $1;
    if not found then
        return '';
    end if;
    if psrec.slotlink = '' then
        return '-';
    end if;
    sltype := substr(psrec.slotlink, 1, 2);
    if sltype = 'PS' then
	retval := trim(psrec.slotlink) || ' -> ';
	return retval || pslot_backlink_view(psrec.slotlink);
    end if;
    if sltype = 'HS' then
        retval := comment from Hub H, HSlot HS
			where HS.slotname = psrec.slotlink
			  and H.name = HS.hubname;
        retval := retval || ' slot ';
	retval := retval || slotno::text from HSlot
			where slotname = psrec.slotlink;
	return retval;
    end if;
    return psrec.slotlink;
end;
$_$;


ALTER FUNCTION public.pslot_slotlink_view(character) OWNER TO ashutoshpg;

--
-- Name: pt_in_widget(point, public.widget); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.pt_in_widget(point, public.widget) RETURNS boolean
    LANGUAGE c STRICT
    AS '/home/ashutoshpg/work/units/pg_dump_test/build/dev/src/test/regress/regress.so', 'pt_in_widget';


ALTER FUNCTION public.pt_in_widget(point, public.widget) OWNER TO ashutoshpg;

--
-- Name: ptest10(integer, integer); Type: PROCEDURE; Schema: public; Owner: ashutoshpg
--

CREATE PROCEDURE public.ptest10(OUT a integer, IN b integer, IN c integer)
    LANGUAGE sql
    AS $$ SELECT b - c $$;


ALTER PROCEDURE public.ptest10(OUT a integer, IN b integer, IN c integer) OWNER TO ashutoshpg;

--
-- Name: ptest10(integer, integer, integer); Type: PROCEDURE; Schema: public; Owner: ashutoshpg
--

CREATE PROCEDURE public.ptest10(IN a integer, IN b integer, IN c integer)
    LANGUAGE sql
    AS $$ SELECT a + b - c $$;


ALTER PROCEDURE public.ptest10(IN a integer, IN b integer, IN c integer) OWNER TO ashutoshpg;

--
-- Name: ptest11(integer[]); Type: PROCEDURE; Schema: public; Owner: ashutoshpg
--

CREATE PROCEDURE public.ptest11(OUT a integer, VARIADIC b integer[])
    LANGUAGE sql
    AS $$ SELECT b[1] + b[2] $$;


ALTER PROCEDURE public.ptest11(OUT a integer, VARIADIC b integer[]) OWNER TO ashutoshpg;

--
-- Name: ptest3(text); Type: PROCEDURE; Schema: public; Owner: ashutoshpg
--

CREATE PROCEDURE public.ptest3(IN y text)
    LANGUAGE sql
    AS $_$
CALL ptest1(y);
CALL ptest1($1);
$_$;


ALTER PROCEDURE public.ptest3(IN y text) OWNER TO ashutoshpg;

--
-- Name: ptest5(integer, text, integer); Type: PROCEDURE; Schema: public; Owner: ashutoshpg
--

CREATE PROCEDURE public.ptest5(IN a integer, IN b text, IN c integer DEFAULT 100)
    LANGUAGE sql
    AS $$
INSERT INTO cp_test VALUES(a, b);
INSERT INTO cp_test VALUES(c, b);
$$;


ALTER PROCEDURE public.ptest5(IN a integer, IN b text, IN c integer) OWNER TO ashutoshpg;

--
-- Name: ptest6(integer, anyelement); Type: PROCEDURE; Schema: public; Owner: ashutoshpg
--

CREATE PROCEDURE public.ptest6(IN a integer, IN b anyelement)
    LANGUAGE sql
    AS $$
SELECT NULL::int;
$$;


ALTER PROCEDURE public.ptest6(IN a integer, IN b anyelement) OWNER TO ashutoshpg;

--
-- Name: ptest6a(anyelement); Type: PROCEDURE; Schema: public; Owner: ashutoshpg
--

CREATE PROCEDURE public.ptest6a(INOUT a anyelement, OUT b anyelement)
    LANGUAGE sql
    AS $_$
SELECT $1, $1;
$_$;


ALTER PROCEDURE public.ptest6a(INOUT a anyelement, OUT b anyelement) OWNER TO ashutoshpg;

--
-- Name: ptest6b(anyelement); Type: PROCEDURE; Schema: public; Owner: ashutoshpg
--

CREATE PROCEDURE public.ptest6b(IN a anyelement, OUT b anyelement, OUT c anyarray)
    LANGUAGE sql
    AS $_$
SELECT $1, array[$1];
$_$;


ALTER PROCEDURE public.ptest6b(IN a anyelement, OUT b anyelement, OUT c anyarray) OWNER TO ashutoshpg;

--
-- Name: ptest6c(anyelement, anyelement); Type: PROCEDURE; Schema: public; Owner: ashutoshpg
--

CREATE PROCEDURE public.ptest6c(INOUT a anyelement, INOUT b anyelement)
    LANGUAGE sql
    AS $_$
SELECT $1, 1;
$_$;


ALTER PROCEDURE public.ptest6c(INOUT a anyelement, INOUT b anyelement) OWNER TO ashutoshpg;

--
-- Name: ptest7(text, text); Type: PROCEDURE; Schema: public; Owner: ashutoshpg
--

CREATE PROCEDURE public.ptest7(IN a text, IN b text)
    LANGUAGE sql
    AS $$
SELECT a = b;
$$;


ALTER PROCEDURE public.ptest7(IN a text, IN b text) OWNER TO ashutoshpg;

--
-- Name: ptest8(text); Type: PROCEDURE; Schema: public; Owner: ashutoshpg
--

CREATE PROCEDURE public.ptest8(IN x text)
    LANGUAGE sql
    BEGIN ATOMIC
END;


ALTER PROCEDURE public.ptest8(IN x text) OWNER TO ashutoshpg;

--
-- Name: ptest9(); Type: PROCEDURE; Schema: public; Owner: ashutoshpg
--

CREATE PROCEDURE public.ptest9(OUT a integer)
    LANGUAGE sql
    AS $$
INSERT INTO cp_test VALUES (1, 'a');
SELECT 1;
$$;


ALTER PROCEDURE public.ptest9(OUT a integer) OWNER TO ashutoshpg;

--
-- Name: raise_test3(integer); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.raise_test3(integer) RETURNS integer
    LANGUAGE plpgsql
    AS $_$
begin
    raise notice 'This message has no parameters (despite having %% signs in it)!';
    return $1;
end;
$_$;


ALTER FUNCTION public.raise_test3(integer) OWNER TO ashutoshpg;

--
-- Name: range_add_bounds(anymultirange); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.range_add_bounds(anymultirange) RETURNS anyelement
    LANGUAGE sql
    AS $_$select lower($1) + upper($1)$_$;


ALTER FUNCTION public.range_add_bounds(anymultirange) OWNER TO ashutoshpg;

--
-- Name: range_add_bounds(anyrange); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.range_add_bounds(anyrange) RETURNS anyelement
    LANGUAGE sql
    AS $_$select lower($1) + upper($1)$_$;


ALTER FUNCTION public.range_add_bounds(anyrange) OWNER TO ashutoshpg;

--
-- Name: rangetypes_sql(anyrange, anyarray); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.rangetypes_sql(q anyrange, b anyarray, OUT c anyelement) RETURNS anyelement
    LANGUAGE sql
    AS $_$ select upper($1) + $2[1] $_$;


ALTER FUNCTION public.rangetypes_sql(q anyrange, b anyarray, OUT c anyelement) OWNER TO ashutoshpg;

--
-- Name: recurse(double precision); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.recurse(double precision) RETURNS double precision
    LANGUAGE plpgsql
    AS $_$
begin
  if ($1 > 0) then
    return sql_recurse($1 - 1);
  else
    return $1;
  end if;
end;
$_$;


ALTER FUNCTION public.recurse(double precision) OWNER TO ashutoshpg;

--
-- Name: recursion_test(integer, integer); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.recursion_test(integer, integer) RETURNS text
    LANGUAGE plpgsql
    AS $_$
DECLARE rslt text;
BEGIN
    IF $1 <= 0 THEN
        rslt = CAST($2 AS TEXT);
    ELSE
        rslt = CAST($1 AS TEXT) || ',' || recursion_test($1 - 1, $2);
    END IF;
    RETURN rslt;
END;$_$;


ALTER FUNCTION public.recursion_test(integer, integer) OWNER TO ashutoshpg;

--
-- Name: refcursor_test1(refcursor); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.refcursor_test1(refcursor) RETURNS refcursor
    LANGUAGE plpgsql
    AS $_$
begin
    perform return_refcursor($1);
    return $1;
end
$_$;


ALTER FUNCTION public.refcursor_test1(refcursor) OWNER TO ashutoshpg;

--
-- Name: refcursor_test2(integer, integer); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.refcursor_test2(integer, integer) RETURNS boolean
    LANGUAGE plpgsql
    AS $_$
declare
    c1 cursor (param1 int, param2 int) for select * from rc_test where a > param1 and b > param2;
    nonsense record;
begin
    open c1($1, $2);
    fetch c1 into nonsense;
    close c1;
    if found then
        return true;
    else
        return false;
    end if;
end
$_$;


ALTER FUNCTION public.refcursor_test2(integer, integer) OWNER TO ashutoshpg;

--
-- Name: report_guc(text); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.report_guc(text) RETURNS text
    LANGUAGE sql
    AS $_$ select current_setting($1) $_$;


ALTER FUNCTION public.report_guc(text) OWNER TO ashutoshpg;

--
-- Name: reraise_test(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.reraise_test() RETURNS void
    LANGUAGE plpgsql
    AS $$
BEGIN
   BEGIN
       RAISE syntax_error;
   EXCEPTION
       WHEN syntax_error THEN
           BEGIN
               raise notice 'exception % thrown in inner block, reraising', sqlerrm;
               RAISE;
           EXCEPTION
               WHEN OTHERS THEN
                   raise notice 'RIGHT - exception % caught in inner block', sqlerrm;
           END;
   END;
EXCEPTION
   WHEN OTHERS THEN
       raise notice 'WRONG - exception % caught in outer block', sqlerrm;
END;
$$;


ALTER FUNCTION public.reraise_test() OWNER TO ashutoshpg;

--
-- Name: ret_query1(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.ret_query1(OUT integer, OUT integer) RETURNS SETOF record
    LANGUAGE plpgsql
    AS $_$
begin
    $1 := -1;
    $2 := -2;
    return next;
    return query select x + 1, x * 10 from generate_series(0, 10) s (x);
    return next;
end;
$_$;


ALTER FUNCTION public.ret_query1(OUT integer, OUT integer) OWNER TO ashutoshpg;

--
-- Name: ret_query2(integer); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.ret_query2(lim integer) RETURNS SETOF public.record_type
    LANGUAGE plpgsql
    AS $$
begin
    return query select fipshash(s.x::text), s.x, s.x > 0
                 from generate_series(-8, lim) s (x) where s.x % 2 = 0;
end;
$$;


ALTER FUNCTION public.ret_query2(lim integer) OWNER TO ashutoshpg;

--
-- Name: return_refcursor(refcursor); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.return_refcursor(rc refcursor) RETURNS refcursor
    LANGUAGE plpgsql
    AS $$
begin
    open rc for select a from rc_test;
    return rc;
end
$$;


ALTER FUNCTION public.return_refcursor(rc refcursor) OWNER TO ashutoshpg;

--
-- Name: return_unnamed_refcursor(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.return_unnamed_refcursor() RETURNS refcursor
    LANGUAGE plpgsql
    AS $$
declare
    rc refcursor;
begin
    open rc for select a from rc_test;
    return rc;
end
$$;


ALTER FUNCTION public.return_unnamed_refcursor() OWNER TO ashutoshpg;

--
-- Name: returns_rw_array(integer); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.returns_rw_array(integer) RETURNS integer[]
    LANGUAGE plpgsql STABLE
    AS $_$
  declare r int[];
  begin r := array[$1, $1]; return r; end;
$_$;


ALTER FUNCTION public.returns_rw_array(integer) OWNER TO ashutoshpg;

--
-- Name: reverse_name(name); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.reverse_name(name) RETURNS name
    LANGUAGE c STRICT
    AS '/home/ashutoshpg/work/units/pg_dump_test/build/dev/src/test/regress/regress.so', 'reverse_name';


ALTER FUNCTION public.reverse_name(name) OWNER TO ashutoshpg;

--
-- Name: rtest_viewfunc1(integer); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.rtest_viewfunc1(integer) RETURNS integer
    LANGUAGE sql
    AS $_$select count(*)::int4 from rtest_view2 where a = $1$_$;


ALTER FUNCTION public.rtest_viewfunc1(integer) OWNER TO ashutoshpg;

--
-- Name: serializable_update_trig(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.serializable_update_trig() RETURNS trigger
    LANGUAGE plpgsql
    AS $$
declare
	rec record;
begin
	new.description = 'updated in trigger';
	return new;
end;
$$;


ALTER FUNCTION public.serializable_update_trig() OWNER TO ashutoshpg;

--
-- Name: set_ttdummy(integer); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.set_ttdummy(integer) RETURNS integer
    LANGUAGE c STRICT
    AS '/home/ashutoshpg/work/units/pg_dump_test/build/dev/src/test/regress/regress.so', 'set_ttdummy';


ALTER FUNCTION public.set_ttdummy(integer) OWNER TO ashutoshpg;

--
-- Name: shadowtest(integer); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.shadowtest(f1 integer) RETURNS boolean
    LANGUAGE plpgsql
    AS $$
declare f1 int; begin return 1; end $$;


ALTER FUNCTION public.shadowtest(f1 integer) OWNER TO ashutoshpg;

--
-- Name: sp_parallel_restricted(integer); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.sp_parallel_restricted(integer) RETURNS integer
    LANGUAGE plpgsql PARALLEL RESTRICTED
    AS $_$begin return $1; end$_$;


ALTER FUNCTION public.sp_parallel_restricted(integer) OWNER TO ashutoshpg;

--
-- Name: sql_if(boolean, anyelement, anyelement); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.sql_if(boolean, anyelement, anyelement) RETURNS anyelement
    LANGUAGE sql
    AS $_$
select case when $1 then $2 else $3 end $_$;


ALTER FUNCTION public.sql_if(boolean, anyelement, anyelement) OWNER TO ashutoshpg;

--
-- Name: sql_recurse(double precision); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.sql_recurse(double precision) RETURNS double precision
    LANGUAGE sql
    AS $_$ select recurse($1) limit 1; $_$;


ALTER FUNCTION public.sql_recurse(double precision) OWNER TO ashutoshpg;

--
-- Name: sro_ifun(integer); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.sro_ifun(integer) RETURNS integer
    LANGUAGE plpgsql IMMUTABLE
    AS $_$
BEGIN
	-- Below we set the table's owner to regress_sro_user
	ASSERT current_user = 'regress_sro_user',
		format('sro_ifun(%s) called by %s', $1, current_user);
	RETURN $1;
END;
$_$;


ALTER FUNCTION public.sro_ifun(integer) OWNER TO ashutoshpg;

--
-- Name: start_command(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.start_command() RETURNS event_trigger
    LANGUAGE plpgsql
    AS $$
BEGIN
RAISE NOTICE '% - ddl_command_start', tg_tag;
END;
$$;


ALTER FUNCTION public.start_command() OWNER TO ashutoshpg;

--
-- Name: stfnp(integer[]); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.stfnp(integer[]) RETURNS integer[]
    LANGUAGE sql
    AS $_$select $1$_$;


ALTER FUNCTION public.stfnp(integer[]) OWNER TO ashutoshpg;

--
-- Name: stfp(anyarray); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.stfp(anyarray) RETURNS anyarray
    LANGUAGE sql
    AS $_$select $1$_$;


ALTER FUNCTION public.stfp(anyarray) OWNER TO ashutoshpg;

--
-- Name: stricttest(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.stricttest() RETURNS void
    LANGUAGE plpgsql
    AS $$
-- override the global
#print_strict_params on
declare
x record;
p1 int := 2;
p3 text := 'foo';
begin
  -- too many rows
  select * from foo where f1 > p1 or f1::text = p3  into strict x;
  raise notice 'x.f1 = %, x.f2 = %', x.f1, x.f2;
end$$;


ALTER FUNCTION public.stricttest() OWNER TO ashutoshpg;

--
-- Name: sum3(anyelement, anyelement, anyelement); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.sum3(anyelement, anyelement, anyelement) RETURNS anyelement
    LANGUAGE sql STRICT
    AS $_$select $1+$2+$3$_$;


ALTER FUNCTION public.sum3(anyelement, anyelement, anyelement) OWNER TO ashutoshpg;

--
-- Name: sum3(bigint, bigint, bigint); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.sum3(bigint, bigint, bigint) RETURNS bigint
    LANGUAGE sql IMMUTABLE STRICT
    AS $_$select $1 + $2 + $3$_$;


ALTER FUNCTION public.sum3(bigint, bigint, bigint) OWNER TO ashutoshpg;

--
-- Name: sum_int_randrestart_minvfunc(integer, integer); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.sum_int_randrestart_minvfunc(integer, integer) RETURNS integer
    LANGUAGE sql STRICT
    AS $_$ SELECT CASE WHEN random() < 0.2 THEN NULL ELSE $1 - $2 END $_$;


ALTER FUNCTION public.sum_int_randrestart_minvfunc(integer, integer) OWNER TO ashutoshpg;

--
-- Name: table_succeed(anyrange); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.table_succeed(r anyrange) RETURNS TABLE(l anyelement, u anyelement)
    LANGUAGE sql
    AS $_$ select lower($1), upper($1) $_$;


ALTER FUNCTION public.table_succeed(r anyrange) OWNER TO ashutoshpg;

--
-- Name: test_atomic_ops(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.test_atomic_ops() RETURNS boolean
    LANGUAGE c
    AS '/home/ashutoshpg/work/units/pg_dump_test/build/dev/src/test/regress/regress.so', 'test_atomic_ops';


ALTER FUNCTION public.test_atomic_ops() OWNER TO ashutoshpg;

--
-- Name: test_canonicalize_path(text); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.test_canonicalize_path(text) RETURNS text
    LANGUAGE c IMMUTABLE STRICT
    AS '/home/ashutoshpg/work/units/pg_dump_test/build/dev/src/test/regress/regress.so', 'test_canonicalize_path';


ALTER FUNCTION public.test_canonicalize_path(text) OWNER TO ashutoshpg;

--
-- Name: test_conv(bytea, text, text); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.test_conv(input bytea, src_encoding text, dst_encoding text, OUT result bytea, OUT errorat bytea, OUT error text) RETURNS record
    LANGUAGE plpgsql
    AS $$
declare
  validlen int;
begin
  -- First try to perform the conversion with noError = false. If that errors out,
  -- capture the error message, and try again with noError = true. The second call
  -- should succeed and return the position of the error, return that too.
  begin
    select * into validlen, result from test_enc_conversion(input, src_encoding, dst_encoding, false);
    errorat = NULL;
    error := NULL;
  exception when others then
    error := sqlerrm;
    select * into validlen, result from test_enc_conversion(input, src_encoding, dst_encoding, true);
    errorat = substr(input, validlen + 1);
  end;
  return;
end;
$$;


ALTER FUNCTION public.test_conv(input bytea, src_encoding text, dst_encoding text, OUT result bytea, OUT errorat bytea, OUT error text) OWNER TO ashutoshpg;

--
-- Name: test_enc_conversion(bytea, name, name, boolean); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.test_enc_conversion(bytea, name, name, boolean, OUT validlen integer, OUT result bytea) RETURNS record
    LANGUAGE c STRICT
    AS '/home/ashutoshpg/work/units/pg_dump_test/build/dev/src/test/regress/regress.so', 'test_enc_conversion';


ALTER FUNCTION public.test_enc_conversion(bytea, name, name, boolean, OUT validlen integer, OUT result bytea) OWNER TO ashutoshpg;

--
-- Name: test_event_trigger(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.test_event_trigger() RETURNS event_trigger
    LANGUAGE plpgsql
    AS $$
BEGIN
    RAISE NOTICE 'test_event_trigger: % %', tg_event, tg_tag;
END
$$;


ALTER FUNCTION public.test_event_trigger() OWNER TO ashutoshpg;

--
-- Name: test_event_trigger_guc(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.test_event_trigger_guc() RETURNS event_trigger
    LANGUAGE plpgsql
    AS $$
DECLARE
	obj record;
BEGIN
	FOR obj IN SELECT * FROM pg_event_trigger_dropped_objects()
	LOOP
		RAISE NOTICE '% dropped %', tg_tag, obj.object_type;
	END LOOP;
END;
$$;


ALTER FUNCTION public.test_event_trigger_guc() OWNER TO ashutoshpg;

--
-- Name: test_evtrig_dropped_objects(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.test_evtrig_dropped_objects() RETURNS event_trigger
    LANGUAGE plpgsql
    AS $$
DECLARE
    obj record;
BEGIN
    FOR obj IN SELECT * FROM pg_event_trigger_dropped_objects()
    LOOP
        IF obj.object_type = 'table' THEN
                EXECUTE format('DROP TABLE IF EXISTS audit_tbls.%I',
					format('%s_%s', obj.schema_name, obj.object_name));
        END IF;

	INSERT INTO dropped_objects
		(type, schema, object) VALUES
		(obj.object_type, obj.schema_name, obj.object_identity);
    END LOOP;
END
$$;


ALTER FUNCTION public.test_evtrig_dropped_objects() OWNER TO ashutoshpg;

--
-- Name: test_fdw_handler(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.test_fdw_handler() RETURNS fdw_handler
    LANGUAGE c
    AS '/home/ashutoshpg/work/units/pg_dump_test/build/dev/src/test/regress/regress.so', 'test_fdw_handler';


ALTER FUNCTION public.test_fdw_handler() OWNER TO ashutoshpg;

--
-- Name: test_found(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.test_found() RETURNS boolean
    LANGUAGE plpgsql
    AS $$
  declare
  begin
  insert into found_test_tbl values (1);
  if FOUND then
     insert into found_test_tbl values (2);
  end if;

  update found_test_tbl set a = 100 where a = 1;
  if FOUND then
    insert into found_test_tbl values (3);
  end if;

  delete from found_test_tbl where a = 9999; -- matches no rows
  if not FOUND then
    insert into found_test_tbl values (4);
  end if;

  for i in 1 .. 10 loop
    -- no need to do anything
  end loop;
  if FOUND then
    insert into found_test_tbl values (5);
  end if;

  -- never executes the loop
  for i in 2 .. 1 loop
    -- no need to do anything
  end loop;
  if not FOUND then
    insert into found_test_tbl values (6);
  end if;
  return true;
  end;$$;


ALTER FUNCTION public.test_found() OWNER TO ashutoshpg;

--
-- Name: test_opclass_options_func(internal); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.test_opclass_options_func(internal) RETURNS void
    LANGUAGE c
    AS '/home/ashutoshpg/work/units/pg_dump_test/build/dev/src/test/regress/regress.so', 'test_opclass_options_func';


ALTER FUNCTION public.test_opclass_options_func(internal) OWNER TO ashutoshpg;

--
-- Name: test_ret_rec_dyn(integer); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.test_ret_rec_dyn(integer) RETURNS record
    LANGUAGE plpgsql
    AS $_$
DECLARE
	retval RECORD;
BEGIN
	IF $1 > 10 THEN
		SELECT INTO retval 5, 10, 15;
		RETURN retval;
	ELSE
		SELECT INTO retval 50, 5::numeric, 'xxx'::text;
		RETURN retval;
	END IF;
END;$_$;


ALTER FUNCTION public.test_ret_rec_dyn(integer) OWNER TO ashutoshpg;

--
-- Name: test_ret_set_rec_dyn(integer); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.test_ret_set_rec_dyn(integer) RETURNS SETOF record
    LANGUAGE plpgsql
    AS $_$
DECLARE
	retval RECORD;
BEGIN
	IF $1 > 10 THEN
		SELECT INTO retval 5, 10, 15;
		RETURN NEXT retval;
		RETURN NEXT retval;
	ELSE
		SELECT INTO retval 50, 5::numeric, 'xxx'::text;
		RETURN NEXT retval;
		RETURN NEXT retval;
	END IF;
	RETURN;
END;$_$;


ALTER FUNCTION public.test_ret_set_rec_dyn(integer) OWNER TO ashutoshpg;

--
-- Name: test_ret_set_scalar(integer, integer); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.test_ret_set_scalar(integer, integer) RETURNS SETOF integer
    LANGUAGE plpgsql
    AS $_$
DECLARE
	i int;
BEGIN
	FOR i IN $1 .. $2 LOOP
		RETURN NEXT i + 1;
	END LOOP;
	RETURN;
END;$_$;


ALTER FUNCTION public.test_ret_set_scalar(integer, integer) OWNER TO ashutoshpg;

--
-- Name: test_strict(text); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.test_strict(text) RETURNS text
    LANGUAGE sql
    AS $_$select coalesce($1, 'got passed a null');$_$;


ALTER FUNCTION public.test_strict(text) OWNER TO ashutoshpg;

--
-- Name: found_test_tbl; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.found_test_tbl (
    a integer
);


ALTER TABLE public.found_test_tbl OWNER TO ashutoshpg;

--
-- Name: test_table_func_rec(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.test_table_func_rec() RETURNS SETOF public.found_test_tbl
    LANGUAGE plpgsql
    AS $$
DECLARE
	rec RECORD;
BEGIN
	FOR rec IN select * from found_test_tbl LOOP
		RETURN NEXT rec;
	END LOOP;
	RETURN;
END;$$;


ALTER FUNCTION public.test_table_func_rec() OWNER TO ashutoshpg;

--
-- Name: test_table_func_row(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.test_table_func_row() RETURNS SETOF public.found_test_tbl
    LANGUAGE plpgsql
    AS $$
DECLARE
	row found_test_tbl%ROWTYPE;
BEGIN
	FOR row IN select * from found_test_tbl LOOP
		RETURN NEXT row;
	END LOOP;
	RETURN;
END;$$;


ALTER FUNCTION public.test_table_func_row() OWNER TO ashutoshpg;

--
-- Name: tf1p(anyarray, integer); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.tf1p(anyarray, integer) RETURNS anyarray
    LANGUAGE sql
    AS $_$select $1$_$;


ALTER FUNCTION public.tf1p(anyarray, integer) OWNER TO ashutoshpg;

--
-- Name: tf2p(integer[], anyelement); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.tf2p(integer[], anyelement) RETURNS integer[]
    LANGUAGE sql
    AS $_$select $1$_$;


ALTER FUNCTION public.tf2p(integer[], anyelement) OWNER TO ashutoshpg;

--
-- Name: tfnp(integer[], integer); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.tfnp(integer[], integer) RETURNS integer[]
    LANGUAGE sql
    AS $_$select $1 || $2$_$;


ALTER FUNCTION public.tfnp(integer[], integer) OWNER TO ashutoshpg;

--
-- Name: tfp(anyarray, anyelement); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.tfp(anyarray, anyelement) RETURNS anyarray
    LANGUAGE sql
    AS $_$select $1 || $2$_$;


ALTER FUNCTION public.tfp(anyarray, anyelement) OWNER TO ashutoshpg;

--
-- Name: tg_backlink_a(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.tg_backlink_a() RETURNS trigger
    LANGUAGE plpgsql
    AS $$
declare
    dummy	integer;
begin
    if tg_op = 'INSERT' then
        if new.backlink != '' then
	    dummy := tg_backlink_set(new.backlink, new.slotname);
	end if;
	return new;
    end if;
    if tg_op = 'UPDATE' then
        if new.backlink != old.backlink then
	    if old.backlink != '' then
	        dummy := tg_backlink_unset(old.backlink, old.slotname);
	    end if;
	    if new.backlink != '' then
	        dummy := tg_backlink_set(new.backlink, new.slotname);
	    end if;
	else
	    if new.slotname != old.slotname and new.backlink != '' then
	        dummy := tg_slotlink_set(new.backlink, new.slotname);
	    end if;
	end if;
	return new;
    end if;
    if tg_op = 'DELETE' then
        if old.backlink != '' then
	    dummy := tg_backlink_unset(old.backlink, old.slotname);
	end if;
	return old;
    end if;
end;
$$;


ALTER FUNCTION public.tg_backlink_a() OWNER TO ashutoshpg;

--
-- Name: tg_backlink_set(character, character); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.tg_backlink_set(myname character, blname character) RETURNS integer
    LANGUAGE plpgsql
    AS $$
declare
    mytype	char(2);
    link	char(4);
    rec		record;
begin
    mytype := substr(myname, 1, 2);
    link := mytype || substr(blname, 1, 2);
    if link = 'PLPL' then
        raise exception
		'backlink between two phone lines does not make sense';
    end if;
    if link in ('PLWS', 'WSPL') then
        raise exception
		'direct link of phone line to wall slot not permitted';
    end if;
    if mytype = 'PS' then
        select into rec * from PSlot where slotname = myname;
	if not found then
	    raise exception '% does not exist', myname;
	end if;
	if rec.backlink != blname then
	    update PSlot set backlink = blname where slotname = myname;
	end if;
	return 0;
    end if;
    if mytype = 'WS' then
        select into rec * from WSlot where slotname = myname;
	if not found then
	    raise exception '% does not exist', myname;
	end if;
	if rec.backlink != blname then
	    update WSlot set backlink = blname where slotname = myname;
	end if;
	return 0;
    end if;
    if mytype = 'PL' then
        select into rec * from PLine where slotname = myname;
	if not found then
	    raise exception '% does not exist', myname;
	end if;
	if rec.backlink != blname then
	    update PLine set backlink = blname where slotname = myname;
	end if;
	return 0;
    end if;
    raise exception 'illegal backlink beginning with %', mytype;
end;
$$;


ALTER FUNCTION public.tg_backlink_set(myname character, blname character) OWNER TO ashutoshpg;

--
-- Name: tg_backlink_unset(character, character); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.tg_backlink_unset(character, character) RETURNS integer
    LANGUAGE plpgsql
    AS $_$
declare
    myname	alias for $1;
    blname	alias for $2;
    mytype	char(2);
    rec		record;
begin
    mytype := substr(myname, 1, 2);
    if mytype = 'PS' then
        select into rec * from PSlot where slotname = myname;
	if not found then
	    return 0;
	end if;
	if rec.backlink = blname then
	    update PSlot set backlink = '' where slotname = myname;
	end if;
	return 0;
    end if;
    if mytype = 'WS' then
        select into rec * from WSlot where slotname = myname;
	if not found then
	    return 0;
	end if;
	if rec.backlink = blname then
	    update WSlot set backlink = '' where slotname = myname;
	end if;
	return 0;
    end if;
    if mytype = 'PL' then
        select into rec * from PLine where slotname = myname;
	if not found then
	    return 0;
	end if;
	if rec.backlink = blname then
	    update PLine set backlink = '' where slotname = myname;
	end if;
	return 0;
    end if;
end
$_$;


ALTER FUNCTION public.tg_backlink_unset(character, character) OWNER TO ashutoshpg;

--
-- Name: tg_chkbacklink(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.tg_chkbacklink() RETURNS trigger
    LANGUAGE plpgsql
    AS $$
begin
    if new.backlink isnull then
        new.backlink := '';
    end if;
    return new;
end;
$$;


ALTER FUNCTION public.tg_chkbacklink() OWNER TO ashutoshpg;

--
-- Name: tg_chkslotlink(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.tg_chkslotlink() RETURNS trigger
    LANGUAGE plpgsql
    AS $$
begin
    if new.slotlink isnull then
        new.slotlink := '';
    end if;
    return new;
end;
$$;


ALTER FUNCTION public.tg_chkslotlink() OWNER TO ashutoshpg;

--
-- Name: tg_chkslotname(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.tg_chkslotname() RETURNS trigger
    LANGUAGE plpgsql
    AS $$
begin
    if substr(new.slotname, 1, 2) != tg_argv[0] then
        raise exception 'slotname must begin with %', tg_argv[0];
    end if;
    return new;
end;
$$;


ALTER FUNCTION public.tg_chkslotname() OWNER TO ashutoshpg;

--
-- Name: tg_hslot_bd(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.tg_hslot_bd() RETURNS trigger
    LANGUAGE plpgsql
    AS $$
declare
    hubrec	record;
begin
    select into hubrec * from Hub where name = old.hubname;
    if not found then
        return old;
    end if;
    if old.slotno > hubrec.nslots then
        return old;
    end if;
    raise exception 'no manual manipulation of HSlot';
end;
$$;


ALTER FUNCTION public.tg_hslot_bd() OWNER TO ashutoshpg;

--
-- Name: tg_hslot_biu(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.tg_hslot_biu() RETURNS trigger
    LANGUAGE plpgsql
    AS $$
declare
    sname	text;
    xname	HSlot.slotname%TYPE;
    hubrec	record;
begin
    select into hubrec * from Hub where name = new.hubname;
    if not found then
        raise exception 'no manual manipulation of HSlot';
    end if;
    if new.slotno < 1 or new.slotno > hubrec.nslots then
        raise exception 'no manual manipulation of HSlot';
    end if;
    if tg_op = 'UPDATE' and new.hubname != old.hubname then
	if count(*) > 0 from Hub where name = old.hubname then
	    raise exception 'no manual manipulation of HSlot';
	end if;
    end if;
    sname := 'HS.' || trim(new.hubname);
    sname := sname || '.';
    sname := sname || new.slotno::text;
    if length(sname) > 20 then
        raise exception 'HSlot slotname "%" too long (20 char max)', sname;
    end if;
    new.slotname := sname;
    return new;
end;
$$;


ALTER FUNCTION public.tg_hslot_biu() OWNER TO ashutoshpg;

--
-- Name: tg_hslot_bu(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.tg_hslot_bu() RETURNS trigger
    LANGUAGE plpgsql
    AS $$
begin
    if new.slotname != old.slotname or new.hubname != old.hubname then
        delete from HSlot where slotname = old.slotname;
	insert into HSlot (
		    slotname,
		    hubname,
		    slotno,
		    slotlink
		) values (
		    new.slotname,
		    new.hubname,
		    new.slotno,
		    new.slotlink
		);
        return null;
    end if;
    return new;
end;
$$;


ALTER FUNCTION public.tg_hslot_bu() OWNER TO ashutoshpg;

--
-- Name: tg_hub_a(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.tg_hub_a() RETURNS trigger
    LANGUAGE plpgsql
    AS $$
declare
    hname	text;
    dummy	integer;
begin
    if tg_op = 'INSERT' then
	dummy := tg_hub_adjustslots(new.name, 0, new.nslots);
	return new;
    end if;
    if tg_op = 'UPDATE' then
	if new.name != old.name then
	    update HSlot set hubname = new.name where hubname = old.name;
	end if;
	dummy := tg_hub_adjustslots(new.name, old.nslots, new.nslots);
	return new;
    end if;
    if tg_op = 'DELETE' then
	dummy := tg_hub_adjustslots(old.name, old.nslots, 0);
	return old;
    end if;
end;
$$;


ALTER FUNCTION public.tg_hub_a() OWNER TO ashutoshpg;

--
-- Name: tg_hub_adjustslots(character, integer, integer); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.tg_hub_adjustslots(hname character, oldnslots integer, newnslots integer) RETURNS integer
    LANGUAGE plpgsql
    AS $$
begin
    if newnslots = oldnslots then
        return 0;
    end if;
    if newnslots < oldnslots then
        delete from HSlot where hubname = hname and slotno > newnslots;
	return 0;
    end if;
    for i in oldnslots + 1 .. newnslots loop
        insert into HSlot (slotname, hubname, slotno, slotlink)
		values ('HS.dummy', hname, i, '');
    end loop;
    return 0;
end
$$;


ALTER FUNCTION public.tg_hub_adjustslots(hname character, oldnslots integer, newnslots integer) OWNER TO ashutoshpg;

--
-- Name: tg_iface_biu(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.tg_iface_biu() RETURNS trigger
    LANGUAGE plpgsql
    AS $_$
declare
    sname	text;
    sysrec	record;
begin
    select into sysrec * from system where name = new.sysname;
    if not found then
        raise exception $q$system "%" does not exist$q$, new.sysname;
    end if;
    sname := 'IF.' || new.sysname;
    sname := sname || '.';
    sname := sname || new.ifname;
    if length(sname) > 20 then
        raise exception 'IFace slotname "%" too long (20 char max)', sname;
    end if;
    new.slotname := sname;
    return new;
end;
$_$;


ALTER FUNCTION public.tg_iface_biu() OWNER TO ashutoshpg;

--
-- Name: tg_iface_bu(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.tg_iface_bu() RETURNS trigger
    LANGUAGE plpgsql
    AS $$
begin
    if new.slotname != old.slotname then
        delete from IFace where slotname = old.slotname;
	insert into IFace (
		    slotname,
		    sysname,
		    ifname,
		    slotlink
		) values (
		    new.slotname,
		    new.sysname,
		    new.ifname,
		    new.slotlink
		);
        return null;
    end if;
    return new;
end;
$$;


ALTER FUNCTION public.tg_iface_bu() OWNER TO ashutoshpg;

--
-- Name: tg_pfield_ad(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.tg_pfield_ad() RETURNS trigger
    LANGUAGE plpgsql
    AS $$
begin
    delete from PSlot where pfname = old.name;
    return old;
end;
$$;


ALTER FUNCTION public.tg_pfield_ad() OWNER TO ashutoshpg;

--
-- Name: tg_pfield_au(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.tg_pfield_au() RETURNS trigger
    LANGUAGE plpgsql
    AS $$
begin
    if new.name != old.name then
        update PSlot set pfname = new.name where pfname = old.name;
    end if;
    return new;
end;
$$;


ALTER FUNCTION public.tg_pfield_au() OWNER TO ashutoshpg;

--
-- Name: tg_phone_bu(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.tg_phone_bu() RETURNS trigger
    LANGUAGE plpgsql
    AS $$
begin
    if new.slotname != old.slotname then
        delete from PHone where slotname = old.slotname;
	insert into PHone (
		    slotname,
		    comment,
		    slotlink
		) values (
		    new.slotname,
		    new.comment,
		    new.slotlink
		);
        return null;
    end if;
    return new;
end;
$$;


ALTER FUNCTION public.tg_phone_bu() OWNER TO ashutoshpg;

--
-- Name: tg_pline_bu(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.tg_pline_bu() RETURNS trigger
    LANGUAGE plpgsql
    AS $$
begin
    if new.slotname != old.slotname then
        delete from PLine where slotname = old.slotname;
	insert into PLine (
		    slotname,
		    phonenumber,
		    comment,
		    backlink
		) values (
		    new.slotname,
		    new.phonenumber,
		    new.comment,
		    new.backlink
		);
        return null;
    end if;
    return new;
end;
$$;


ALTER FUNCTION public.tg_pline_bu() OWNER TO ashutoshpg;

--
-- Name: tg_pslot_biu(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.tg_pslot_biu() RETURNS trigger
    LANGUAGE plpgsql
    AS $_$
declare
    pfrec	record;
    ps          alias for new;
begin
    select into pfrec * from PField where name = ps.pfname;
    if not found then
        raise exception $$Patchfield "%" does not exist$$, ps.pfname;
    end if;
    return ps;
end;
$_$;


ALTER FUNCTION public.tg_pslot_biu() OWNER TO ashutoshpg;

--
-- Name: tg_pslot_bu(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.tg_pslot_bu() RETURNS trigger
    LANGUAGE plpgsql
    AS $$
begin
    if new.slotname != old.slotname then
        delete from PSlot where slotname = old.slotname;
	insert into PSlot (
		    slotname,
		    pfname,
		    slotlink,
		    backlink
		) values (
		    new.slotname,
		    new.pfname,
		    new.slotlink,
		    new.backlink
		);
        return null;
    end if;
    return new;
end;
$$;


ALTER FUNCTION public.tg_pslot_bu() OWNER TO ashutoshpg;

--
-- Name: tg_room_ad(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.tg_room_ad() RETURNS trigger
    LANGUAGE plpgsql
    AS $$
begin
    delete from WSlot where roomno = old.roomno;
    return old;
end;
$$;


ALTER FUNCTION public.tg_room_ad() OWNER TO ashutoshpg;

--
-- Name: tg_room_au(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.tg_room_au() RETURNS trigger
    LANGUAGE plpgsql
    AS $$
begin
    if new.roomno != old.roomno then
        update WSlot set roomno = new.roomno where roomno = old.roomno;
    end if;
    return new;
end;
$$;


ALTER FUNCTION public.tg_room_au() OWNER TO ashutoshpg;

--
-- Name: tg_slotlink_a(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.tg_slotlink_a() RETURNS trigger
    LANGUAGE plpgsql
    AS $$
declare
    dummy	integer;
begin
    if tg_op = 'INSERT' then
        if new.slotlink != '' then
	    dummy := tg_slotlink_set(new.slotlink, new.slotname);
	end if;
	return new;
    end if;
    if tg_op = 'UPDATE' then
        if new.slotlink != old.slotlink then
	    if old.slotlink != '' then
	        dummy := tg_slotlink_unset(old.slotlink, old.slotname);
	    end if;
	    if new.slotlink != '' then
	        dummy := tg_slotlink_set(new.slotlink, new.slotname);
	    end if;
	else
	    if new.slotname != old.slotname and new.slotlink != '' then
	        dummy := tg_slotlink_set(new.slotlink, new.slotname);
	    end if;
	end if;
	return new;
    end if;
    if tg_op = 'DELETE' then
        if old.slotlink != '' then
	    dummy := tg_slotlink_unset(old.slotlink, old.slotname);
	end if;
	return old;
    end if;
end;
$$;


ALTER FUNCTION public.tg_slotlink_a() OWNER TO ashutoshpg;

--
-- Name: tg_slotlink_set(character, character); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.tg_slotlink_set(character, character) RETURNS integer
    LANGUAGE plpgsql
    AS $_$
declare
    myname	alias for $1;
    blname	alias for $2;
    mytype	char(2);
    link	char(4);
    rec		record;
begin
    mytype := substr(myname, 1, 2);
    link := mytype || substr(blname, 1, 2);
    if link = 'PHPH' then
        raise exception
		'slotlink between two phones does not make sense';
    end if;
    if link in ('PHHS', 'HSPH') then
        raise exception
		'link of phone to hub does not make sense';
    end if;
    if link in ('PHIF', 'IFPH') then
        raise exception
		'link of phone to hub does not make sense';
    end if;
    if link in ('PSWS', 'WSPS') then
        raise exception
		'slotlink from patchslot to wallslot not permitted';
    end if;
    if mytype = 'PS' then
        select into rec * from PSlot where slotname = myname;
	if not found then
	    raise exception '% does not exist', myname;
	end if;
	if rec.slotlink != blname then
	    update PSlot set slotlink = blname where slotname = myname;
	end if;
	return 0;
    end if;
    if mytype = 'WS' then
        select into rec * from WSlot where slotname = myname;
	if not found then
	    raise exception '% does not exist', myname;
	end if;
	if rec.slotlink != blname then
	    update WSlot set slotlink = blname where slotname = myname;
	end if;
	return 0;
    end if;
    if mytype = 'IF' then
        select into rec * from IFace where slotname = myname;
	if not found then
	    raise exception '% does not exist', myname;
	end if;
	if rec.slotlink != blname then
	    update IFace set slotlink = blname where slotname = myname;
	end if;
	return 0;
    end if;
    if mytype = 'HS' then
        select into rec * from HSlot where slotname = myname;
	if not found then
	    raise exception '% does not exist', myname;
	end if;
	if rec.slotlink != blname then
	    update HSlot set slotlink = blname where slotname = myname;
	end if;
	return 0;
    end if;
    if mytype = 'PH' then
        select into rec * from PHone where slotname = myname;
	if not found then
	    raise exception '% does not exist', myname;
	end if;
	if rec.slotlink != blname then
	    update PHone set slotlink = blname where slotname = myname;
	end if;
	return 0;
    end if;
    raise exception 'illegal slotlink beginning with %', mytype;
end;
$_$;


ALTER FUNCTION public.tg_slotlink_set(character, character) OWNER TO ashutoshpg;

--
-- Name: tg_slotlink_unset(character, character); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.tg_slotlink_unset(character, character) RETURNS integer
    LANGUAGE plpgsql
    AS $_$
declare
    myname	alias for $1;
    blname	alias for $2;
    mytype	char(2);
    rec		record;
begin
    mytype := substr(myname, 1, 2);
    if mytype = 'PS' then
        select into rec * from PSlot where slotname = myname;
	if not found then
	    return 0;
	end if;
	if rec.slotlink = blname then
	    update PSlot set slotlink = '' where slotname = myname;
	end if;
	return 0;
    end if;
    if mytype = 'WS' then
        select into rec * from WSlot where slotname = myname;
	if not found then
	    return 0;
	end if;
	if rec.slotlink = blname then
	    update WSlot set slotlink = '' where slotname = myname;
	end if;
	return 0;
    end if;
    if mytype = 'IF' then
        select into rec * from IFace where slotname = myname;
	if not found then
	    return 0;
	end if;
	if rec.slotlink = blname then
	    update IFace set slotlink = '' where slotname = myname;
	end if;
	return 0;
    end if;
    if mytype = 'HS' then
        select into rec * from HSlot where slotname = myname;
	if not found then
	    return 0;
	end if;
	if rec.slotlink = blname then
	    update HSlot set slotlink = '' where slotname = myname;
	end if;
	return 0;
    end if;
    if mytype = 'PH' then
        select into rec * from PHone where slotname = myname;
	if not found then
	    return 0;
	end if;
	if rec.slotlink = blname then
	    update PHone set slotlink = '' where slotname = myname;
	end if;
	return 0;
    end if;
end;
$_$;


ALTER FUNCTION public.tg_slotlink_unset(character, character) OWNER TO ashutoshpg;

--
-- Name: tg_system_au(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.tg_system_au() RETURNS trigger
    LANGUAGE plpgsql
    AS $$
begin
    if new.name != old.name then
        update IFace set sysname = new.name where sysname = old.name;
    end if;
    return new;
end;
$$;


ALTER FUNCTION public.tg_system_au() OWNER TO ashutoshpg;

--
-- Name: tg_wslot_biu(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.tg_wslot_biu() RETURNS trigger
    LANGUAGE plpgsql
    AS $$
begin
    if count(*) = 0 from Room where roomno = new.roomno then
        raise exception 'Room % does not exist', new.roomno;
    end if;
    return new;
end;
$$;


ALTER FUNCTION public.tg_wslot_biu() OWNER TO ashutoshpg;

--
-- Name: tg_wslot_bu(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.tg_wslot_bu() RETURNS trigger
    LANGUAGE plpgsql
    AS $$
begin
    if new.slotname != old.slotname then
        delete from WSlot where slotname = old.slotname;
	insert into WSlot (
		    slotname,
		    roomno,
		    slotlink,
		    backlink
		) values (
		    new.slotname,
		    new.roomno,
		    new.slotlink,
		    new.backlink
		);
        return null;
    end if;
    return new;
end;
$$;


ALTER FUNCTION public.tg_wslot_bu() OWNER TO ashutoshpg;

--
-- Name: trans_updatetrigfunc(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.trans_updatetrigfunc() RETURNS trigger
    LANGUAGE plpgsql
    AS $$
  begin
    raise notice 'trigger = %, old table = %, new table = %',
                 TG_NAME,
                 (select string_agg(old_table::text, ', ' ORDER BY a) FROM old_table),
                 (select string_agg(new_table::text, ', ' ORDER BY a) FROM new_table);
    return null;
  end;
$$;


ALTER FUNCTION public.trans_updatetrigfunc() OWNER TO ashutoshpg;

--
-- Name: transition_table_base_ins_func(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.transition_table_base_ins_func() RETURNS trigger
    LANGUAGE plpgsql
    AS $_$
DECLARE
  t text;
  l text;
BEGIN
  t = '';
  FOR l IN EXECUTE
           $q$
             EXPLAIN (TIMING off, COSTS off, VERBOSE on)
             SELECT * FROM newtable
           $q$ LOOP
    t = t || l || E'\n';
  END LOOP;

  RAISE INFO '%', t;
  RETURN new;
END;
$_$;


ALTER FUNCTION public.transition_table_base_ins_func() OWNER TO ashutoshpg;

--
-- Name: transition_table_base_upd_func(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.transition_table_base_upd_func() RETURNS trigger
    LANGUAGE plpgsql
    AS $_$
DECLARE
  t text;
  l text;
BEGIN
  t = '';
  FOR l IN EXECUTE
           $q$
             EXPLAIN (TIMING off, COSTS off, VERBOSE on)
             SELECT * FROM oldtable ot FULL JOIN newtable nt USING (id)
           $q$ LOOP
    t = t || l || E'\n';
  END LOOP;

  RAISE INFO '%', t;
  RETURN new;
END;
$_$;


ALTER FUNCTION public.transition_table_base_upd_func() OWNER TO ashutoshpg;

--
-- Name: transition_table_level1_ri_parent_del_func(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.transition_table_level1_ri_parent_del_func() RETURNS trigger
    LANGUAGE plpgsql
    AS $$
  DECLARE n bigint;
  BEGIN
    PERFORM FROM p JOIN transition_table_level2 c ON c.parent_no = p.level1_no;
    IF FOUND THEN
      RAISE EXCEPTION 'RI error';
    END IF;
    RETURN NULL;
  END;
$$;


ALTER FUNCTION public.transition_table_level1_ri_parent_del_func() OWNER TO ashutoshpg;

--
-- Name: transition_table_level1_ri_parent_upd_func(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.transition_table_level1_ri_parent_upd_func() RETURNS trigger
    LANGUAGE plpgsql
    AS $$
  DECLARE
    x int;
  BEGIN
    WITH p AS (SELECT level1_no, sum(delta) cnt
                 FROM (SELECT level1_no, 1 AS delta FROM i
                       UNION ALL
                       SELECT level1_no, -1 AS delta FROM d) w
                 GROUP BY level1_no
                 HAVING sum(delta) < 0)
    SELECT level1_no
      FROM p JOIN transition_table_level2 c ON c.parent_no = p.level1_no
      INTO x;
    IF FOUND THEN
      RAISE EXCEPTION 'RI error';
    END IF;
    RETURN NULL;
  END;
$$;


ALTER FUNCTION public.transition_table_level1_ri_parent_upd_func() OWNER TO ashutoshpg;

--
-- Name: transition_table_level2_bad_usage_func(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.transition_table_level2_bad_usage_func() RETURNS trigger
    LANGUAGE plpgsql
    AS $$
  BEGIN
    INSERT INTO dx VALUES (1000000, 1000000, 'x');
    RETURN NULL;
  END;
$$;


ALTER FUNCTION public.transition_table_level2_bad_usage_func() OWNER TO ashutoshpg;

--
-- Name: transition_table_level2_ri_child_insupd_func(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.transition_table_level2_ri_child_insupd_func() RETURNS trigger
    LANGUAGE plpgsql
    AS $$
  BEGIN
    PERFORM FROM i
      LEFT JOIN transition_table_level1 p
        ON p.level1_no IS NOT NULL AND p.level1_no = i.parent_no
      WHERE p.level1_no IS NULL;
    IF FOUND THEN
      RAISE EXCEPTION 'RI error';
    END IF;
    RETURN NULL;
  END;
$$;


ALTER FUNCTION public.transition_table_level2_ri_child_insupd_func() OWNER TO ashutoshpg;

--
-- Name: trig_nothing(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.trig_nothing() RETURNS trigger
    LANGUAGE plpgsql
    AS $$ begin return null; end $$;


ALTER FUNCTION public.trig_nothing() OWNER TO ashutoshpg;

--
-- Name: trigfunc(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.trigfunc() RETURNS trigger
    LANGUAGE plpgsql
    AS $$
  begin
    raise notice 'trigger = % fired on table % during %',
                 TG_NAME, TG_TABLE_NAME, TG_OP;
    return null;
  end;
$$;


ALTER FUNCTION public.trigfunc() OWNER TO ashutoshpg;

--
-- Name: trigger_func(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.trigger_func() RETURNS trigger
    LANGUAGE plpgsql
    AS $$
BEGIN
	RAISE NOTICE 'trigger_func(%) called: action = %, when = %, level = %', TG_ARGV[0], TG_OP, TG_WHEN, TG_LEVEL;
	RETURN NULL;
END;$$;


ALTER FUNCTION public.trigger_func() OWNER TO ashutoshpg;

--
-- Name: trigger_notice(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.trigger_notice() RETURNS trigger
    LANGUAGE plpgsql
    AS $$
  declare
    arg1 text = TG_ARGV[0];
    arg2 integer = TG_ARGV[1];
  begin
    raise notice 'trigger % on % % % for % args % %',
		TG_NAME, TG_TABLE_NAME, TG_WHEN, TG_OP, TG_LEVEL, arg1, arg2;
    return null;
  end;
  $$;


ALTER FUNCTION public.trigger_notice() OWNER TO ashutoshpg;

--
-- Name: trigger_parted_trigfunc(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.trigger_parted_trigfunc() RETURNS trigger
    LANGUAGE plpgsql
    AS $$ begin end; $$;


ALTER FUNCTION public.trigger_parted_trigfunc() OWNER TO ashutoshpg;

--
-- Name: trigger_return_old(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.trigger_return_old() RETURNS trigger
    LANGUAGE c
    AS '/home/ashutoshpg/work/units/pg_dump_test/build/dev/src/test/regress/regress.so', 'trigger_return_old';


ALTER FUNCTION public.trigger_return_old() OWNER TO ashutoshpg;

--
-- Name: trigtest(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.trigtest() RETURNS trigger
    LANGUAGE plpgsql
    AS $$
begin
	raise notice '% % % %', TG_TABLE_NAME, TG_OP, TG_WHEN, TG_LEVEL;
	return new;
end;$$;


ALTER FUNCTION public.trigtest() OWNER TO ashutoshpg;

--
-- Name: ttdummy(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.ttdummy() RETURNS trigger
    LANGUAGE c
    AS '/home/ashutoshpg/work/units/pg_dump_test/build/dev/src/test/regress/regress.so', 'ttdummy';


ALTER FUNCTION public.ttdummy() OWNER TO ashutoshpg;

--
-- Name: undroppable(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.undroppable() RETURNS event_trigger
    LANGUAGE plpgsql
    AS $$
DECLARE
	obj record;
BEGIN
	PERFORM 1 FROM pg_tables WHERE tablename = 'undroppable_objs';
	IF NOT FOUND THEN
		RAISE NOTICE 'table undroppable_objs not found, skipping';
		RETURN;
	END IF;
	FOR obj IN
		SELECT * FROM pg_event_trigger_dropped_objects() JOIN
			undroppable_objs USING (object_type, object_identity)
	LOOP
		RAISE EXCEPTION 'object % of type % cannot be dropped',
			obj.object_identity, obj.object_type;
	END LOOP;
END;
$$;


ALTER FUNCTION public.undroppable() OWNER TO ashutoshpg;

--
-- Name: use_refcursor(refcursor); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.use_refcursor(rc refcursor) RETURNS integer
    LANGUAGE plpgsql
    AS $$
declare
    rc refcursor;
    x record;
begin
    rc := return_unnamed_refcursor();
    fetch next from rc into x;
    return x.a;
end
$$;


ALTER FUNCTION public.use_refcursor(rc refcursor) OWNER TO ashutoshpg;

--
-- Name: view_trigger(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.view_trigger() RETURNS trigger
    LANGUAGE plpgsql
    AS $$
declare
    argstr text := '';
begin
    for i in 0 .. TG_nargs - 1 loop
        if i > 0 then
            argstr := argstr || ', ';
        end if;
        argstr := argstr || TG_argv[i];
    end loop;

    raise notice '% % % % (%)', TG_TABLE_NAME, TG_WHEN, TG_OP, TG_LEVEL, argstr;

    if TG_LEVEL = 'ROW' then
        if TG_OP = 'INSERT' then
            raise NOTICE 'NEW: %', NEW;
            INSERT INTO main_table VALUES (NEW.a, NEW.b);
            RETURN NEW;
        end if;

        if TG_OP = 'UPDATE' then
            raise NOTICE 'OLD: %, NEW: %', OLD, NEW;
            UPDATE main_table SET a = NEW.a, b = NEW.b WHERE a = OLD.a AND b = OLD.b;
            if NOT FOUND then RETURN NULL; end if;
            RETURN NEW;
        end if;

        if TG_OP = 'DELETE' then
            raise NOTICE 'OLD: %', OLD;
            DELETE FROM main_table WHERE a = OLD.a AND b = OLD.b;
            if NOT FOUND then RETURN NULL; end if;
            RETURN OLD;
        end if;
    end if;

    RETURN NULL;
end;
$$;


ALTER FUNCTION public.view_trigger() OWNER TO ashutoshpg;

--
-- Name: whoami(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.whoami() RETURNS text
    LANGUAGE sql
    AS $$select 'public'::text$$;


ALTER FUNCTION public.whoami() OWNER TO ashutoshpg;

--
-- Name: wrap_do_analyze(integer); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.wrap_do_analyze(c integer) RETURNS integer
    LANGUAGE sql IMMUTABLE
    AS $_$SELECT $1 FROM public.do_analyze()$_$;


ALTER FUNCTION public.wrap_do_analyze(c integer) OWNER TO ashutoshpg;

--
-- Name: wslot_slotlink_view(character); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.wslot_slotlink_view(character) RETURNS text
    LANGUAGE plpgsql
    AS $_$
declare
    rec		record;
    sltype	char(2);
    retval	text;
begin
    select into rec * from WSlot where slotname = $1;
    if not found then
        return '';
    end if;
    if rec.slotlink = '' then
        return '-';
    end if;
    sltype := substr(rec.slotlink, 1, 2);
    if sltype = 'PH' then
        select into rec * from PHone where slotname = rec.slotlink;
	retval := 'Phone ' || trim(rec.slotname);
	if rec.comment != '' then
	    retval := retval || ' (';
	    retval := retval || rec.comment;
	    retval := retval || ')';
	end if;
	return retval;
    end if;
    if sltype = 'IF' then
	declare
	    syrow	System%RowType;
	    ifrow	IFace%ROWTYPE;
        begin
	    select into ifrow * from IFace where slotname = rec.slotlink;
	    select into syrow * from System where name = ifrow.sysname;
	    retval := syrow.name || ' IF ';
	    retval := retval || ifrow.ifname;
	    if syrow.comment != '' then
	        retval := retval || ' (';
		retval := retval || syrow.comment;
		retval := retval || ')';
	    end if;
	    return retval;
	end;
    end if;
    return rec.slotlink;
end;
$_$;


ALTER FUNCTION public.wslot_slotlink_view(character) OWNER TO ashutoshpg;

--
-- Name: xtrig(); Type: FUNCTION; Schema: public; Owner: ashutoshpg
--

CREATE FUNCTION public.xtrig() RETURNS trigger
    LANGUAGE plpgsql
    AS $$
  declare
    r record;
  begin
    for r in select * from old loop
      raise info 'a=%, b=%', r.a, r.b;
    end loop;
    return NULL;
  end;
$$;


ALTER FUNCTION public.xtrig() OWNER TO ashutoshpg;

--
-- Name: aggfns(integer, integer, text); Type: AGGREGATE; Schema: public; Owner: ashutoshpg
--

CREATE AGGREGATE public.aggfns(integer, integer, text) (
    SFUNC = public.aggfns_trans,
    STYPE = public.aggtype[],
    SSPACE = 10000,
    INITCOND = '{}'
);


ALTER AGGREGATE public.aggfns(integer, integer, text) OWNER TO ashutoshpg;

--
-- Name: aggfstr(integer, integer, text); Type: AGGREGATE; Schema: public; Owner: ashutoshpg
--

CREATE AGGREGATE public.aggfstr(integer, integer, text) (
    SFUNC = public.aggf_trans,
    STYPE = public.aggtype[],
    INITCOND = '{}'
);


ALTER AGGREGATE public.aggfstr(integer, integer, text) OWNER TO ashutoshpg;

--
-- Name: array_larger_accum(anyarray); Type: AGGREGATE; Schema: public; Owner: ashutoshpg
--

CREATE AGGREGATE public.array_larger_accum(anyarray) (
    SFUNC = array_larger,
    STYPE = anyarray,
    INITCOND = '{}'
);


ALTER AGGREGATE public.array_larger_accum(anyarray) OWNER TO ashutoshpg;

--
-- Name: build_group(anyelement, integer); Type: AGGREGATE; Schema: public; Owner: ashutoshpg
--

CREATE AGGREGATE public.build_group(anyelement, integer) (
    SFUNC = public.add_group,
    STYPE = anyarray
);


ALTER AGGREGATE public.build_group(anyelement, integer) OWNER TO ashutoshpg;

--
-- Name: build_group(bigint, integer); Type: AGGREGATE; Schema: public; Owner: ashutoshpg
--

CREATE AGGREGATE public.build_group(bigint, integer) (
    SFUNC = public.add_group,
    STYPE = bigint[]
);


ALTER AGGREGATE public.build_group(bigint, integer) OWNER TO ashutoshpg;

--
-- Name: cleast_agg(anycompatiblearray); Type: AGGREGATE; Schema: public; Owner: ashutoshpg
--

CREATE AGGREGATE public.cleast_agg(VARIADIC items anycompatiblearray) (
    SFUNC = public.cleast_accum,
    STYPE = anycompatible
);


ALTER AGGREGATE public.cleast_agg(VARIADIC items anycompatiblearray) OWNER TO ashutoshpg;

--
-- Name: first_el_agg_any(anyelement); Type: AGGREGATE; Schema: public; Owner: ashutoshpg
--

CREATE AGGREGATE public.first_el_agg_any(anyelement) (
    SFUNC = public.first_el_transfn,
    STYPE = anyarray,
    FINALFUNC = public.first_el
);


ALTER AGGREGATE public.first_el_agg_any(anyelement) OWNER TO ashutoshpg;

--
-- Name: first_el_agg_f8(double precision); Type: AGGREGATE; Schema: public; Owner: ashutoshpg
--

CREATE AGGREGATE public.first_el_agg_f8(double precision) (
    SFUNC = array_append,
    STYPE = double precision[],
    FINALFUNC = public.first_el
);


ALTER AGGREGATE public.first_el_agg_f8(double precision) OWNER TO ashutoshpg;

--
-- Name: least_agg(anyarray); Type: AGGREGATE; Schema: public; Owner: ashutoshpg
--

CREATE AGGREGATE public.least_agg(VARIADIC items anyarray) (
    SFUNC = public.least_accum,
    STYPE = anyelement
);


ALTER AGGREGATE public.least_agg(VARIADIC items anyarray) OWNER TO ashutoshpg;

--
-- Name: logging_agg_nonstrict(anyelement); Type: AGGREGATE; Schema: public; Owner: ashutoshpg
--

CREATE AGGREGATE public.logging_agg_nonstrict(anyelement) (
    SFUNC = public.logging_sfunc_nonstrict,
    STYPE = text,
    MSFUNC = public.logging_msfunc_nonstrict,
    MINVFUNC = public.logging_minvfunc_nonstrict,
    MSTYPE = text
);


ALTER AGGREGATE public.logging_agg_nonstrict(anyelement) OWNER TO ashutoshpg;

--
-- Name: logging_agg_nonstrict_initcond(anyelement); Type: AGGREGATE; Schema: public; Owner: ashutoshpg
--

CREATE AGGREGATE public.logging_agg_nonstrict_initcond(anyelement) (
    SFUNC = public.logging_sfunc_nonstrict,
    STYPE = text,
    INITCOND = 'I',
    MSFUNC = public.logging_msfunc_nonstrict,
    MINVFUNC = public.logging_minvfunc_nonstrict,
    MSTYPE = text,
    MINITCOND = 'MI'
);


ALTER AGGREGATE public.logging_agg_nonstrict_initcond(anyelement) OWNER TO ashutoshpg;

--
-- Name: logging_agg_strict(text); Type: AGGREGATE; Schema: public; Owner: ashutoshpg
--

CREATE AGGREGATE public.logging_agg_strict(text) (
    SFUNC = public.logging_sfunc_strict,
    STYPE = text,
    MSFUNC = public.logging_msfunc_strict,
    MINVFUNC = public.logging_minvfunc_strict,
    MSTYPE = text
);


ALTER AGGREGATE public.logging_agg_strict(text) OWNER TO ashutoshpg;

--
-- Name: logging_agg_strict_initcond(anyelement); Type: AGGREGATE; Schema: public; Owner: ashutoshpg
--

CREATE AGGREGATE public.logging_agg_strict_initcond(anyelement) (
    SFUNC = public.logging_sfunc_strict,
    STYPE = text,
    INITCOND = 'I',
    MSFUNC = public.logging_msfunc_strict,
    MINVFUNC = public.logging_minvfunc_strict,
    MSTYPE = text,
    MINITCOND = 'MI'
);


ALTER AGGREGATE public.logging_agg_strict_initcond(anyelement) OWNER TO ashutoshpg;

--
-- Name: myaggn01a(*); Type: AGGREGATE; Schema: public; Owner: ashutoshpg
--

CREATE AGGREGATE public.myaggn01a(*) (
    SFUNC = public.stfnp,
    STYPE = integer[],
    INITCOND = '{}',
    FINALFUNC = public.ffnp
);


ALTER AGGREGATE public.myaggn01a(*) OWNER TO ashutoshpg;

--
-- Name: myaggn01b(*); Type: AGGREGATE; Schema: public; Owner: ashutoshpg
--

CREATE AGGREGATE public.myaggn01b(*) (
    SFUNC = public.stfnp,
    STYPE = integer[],
    INITCOND = '{}'
);


ALTER AGGREGATE public.myaggn01b(*) OWNER TO ashutoshpg;

--
-- Name: myaggn03a(*); Type: AGGREGATE; Schema: public; Owner: ashutoshpg
--

CREATE AGGREGATE public.myaggn03a(*) (
    SFUNC = public.stfp,
    STYPE = integer[],
    INITCOND = '{}',
    FINALFUNC = public.ffnp
);


ALTER AGGREGATE public.myaggn03a(*) OWNER TO ashutoshpg;

--
-- Name: myaggn05a(integer); Type: AGGREGATE; Schema: public; Owner: ashutoshpg
--

CREATE AGGREGATE public.myaggn05a(integer) (
    SFUNC = public.tfnp,
    STYPE = integer[],
    INITCOND = '{}',
    FINALFUNC = public.ffnp
);


ALTER AGGREGATE public.myaggn05a(integer) OWNER TO ashutoshpg;

--
-- Name: myaggn05b(integer); Type: AGGREGATE; Schema: public; Owner: ashutoshpg
--

CREATE AGGREGATE public.myaggn05b(integer) (
    SFUNC = public.tfnp,
    STYPE = integer[],
    INITCOND = '{}'
);


ALTER AGGREGATE public.myaggn05b(integer) OWNER TO ashutoshpg;

--
-- Name: myaggn06a(integer); Type: AGGREGATE; Schema: public; Owner: ashutoshpg
--

CREATE AGGREGATE public.myaggn06a(integer) (
    SFUNC = public.tf2p,
    STYPE = integer[],
    INITCOND = '{}',
    FINALFUNC = public.ffnp
);


ALTER AGGREGATE public.myaggn06a(integer) OWNER TO ashutoshpg;

--
-- Name: myaggn06b(integer); Type: AGGREGATE; Schema: public; Owner: ashutoshpg
--

CREATE AGGREGATE public.myaggn06b(integer) (
    SFUNC = public.tf2p,
    STYPE = integer[],
    INITCOND = '{}'
);


ALTER AGGREGATE public.myaggn06b(integer) OWNER TO ashutoshpg;

--
-- Name: myaggn08a(anyelement); Type: AGGREGATE; Schema: public; Owner: ashutoshpg
--

CREATE AGGREGATE public.myaggn08a(anyelement) (
    SFUNC = public.tf2p,
    STYPE = integer[],
    INITCOND = '{}',
    FINALFUNC = public.ffnp
);


ALTER AGGREGATE public.myaggn08a(anyelement) OWNER TO ashutoshpg;

--
-- Name: myaggn08b(anyelement); Type: AGGREGATE; Schema: public; Owner: ashutoshpg
--

CREATE AGGREGATE public.myaggn08b(anyelement) (
    SFUNC = public.tf2p,
    STYPE = integer[],
    INITCOND = '{}'
);


ALTER AGGREGATE public.myaggn08b(anyelement) OWNER TO ashutoshpg;

--
-- Name: myaggn09a(integer); Type: AGGREGATE; Schema: public; Owner: ashutoshpg
--

CREATE AGGREGATE public.myaggn09a(integer) (
    SFUNC = public.tf1p,
    STYPE = integer[],
    INITCOND = '{}',
    FINALFUNC = public.ffnp
);


ALTER AGGREGATE public.myaggn09a(integer) OWNER TO ashutoshpg;

--
-- Name: myaggn10a(integer); Type: AGGREGATE; Schema: public; Owner: ashutoshpg
--

CREATE AGGREGATE public.myaggn10a(integer) (
    SFUNC = public.tfp,
    STYPE = integer[],
    INITCOND = '{}',
    FINALFUNC = public.ffnp
);


ALTER AGGREGATE public.myaggn10a(integer) OWNER TO ashutoshpg;

--
-- Name: myaggp01a(*); Type: AGGREGATE; Schema: public; Owner: ashutoshpg
--

CREATE AGGREGATE public.myaggp01a(*) (
    SFUNC = public.stfnp,
    STYPE = integer[],
    INITCOND = '{}',
    FINALFUNC = public.ffp
);


ALTER AGGREGATE public.myaggp01a(*) OWNER TO ashutoshpg;

--
-- Name: myaggp03a(*); Type: AGGREGATE; Schema: public; Owner: ashutoshpg
--

CREATE AGGREGATE public.myaggp03a(*) (
    SFUNC = public.stfp,
    STYPE = integer[],
    INITCOND = '{}',
    FINALFUNC = public.ffp
);


ALTER AGGREGATE public.myaggp03a(*) OWNER TO ashutoshpg;

--
-- Name: myaggp03b(*); Type: AGGREGATE; Schema: public; Owner: ashutoshpg
--

CREATE AGGREGATE public.myaggp03b(*) (
    SFUNC = public.stfp,
    STYPE = integer[],
    INITCOND = '{}'
);


ALTER AGGREGATE public.myaggp03b(*) OWNER TO ashutoshpg;

--
-- Name: myaggp05a(integer); Type: AGGREGATE; Schema: public; Owner: ashutoshpg
--

CREATE AGGREGATE public.myaggp05a(integer) (
    SFUNC = public.tfnp,
    STYPE = integer[],
    INITCOND = '{}',
    FINALFUNC = public.ffp
);


ALTER AGGREGATE public.myaggp05a(integer) OWNER TO ashutoshpg;

--
-- Name: myaggp06a(integer); Type: AGGREGATE; Schema: public; Owner: ashutoshpg
--

CREATE AGGREGATE public.myaggp06a(integer) (
    SFUNC = public.tf2p,
    STYPE = integer[],
    INITCOND = '{}',
    FINALFUNC = public.ffp
);


ALTER AGGREGATE public.myaggp06a(integer) OWNER TO ashutoshpg;

--
-- Name: myaggp08a(anyelement); Type: AGGREGATE; Schema: public; Owner: ashutoshpg
--

CREATE AGGREGATE public.myaggp08a(anyelement) (
    SFUNC = public.tf2p,
    STYPE = integer[],
    INITCOND = '{}',
    FINALFUNC = public.ffp
);


ALTER AGGREGATE public.myaggp08a(anyelement) OWNER TO ashutoshpg;

--
-- Name: myaggp09a(integer); Type: AGGREGATE; Schema: public; Owner: ashutoshpg
--

CREATE AGGREGATE public.myaggp09a(integer) (
    SFUNC = public.tf1p,
    STYPE = integer[],
    INITCOND = '{}',
    FINALFUNC = public.ffp
);


ALTER AGGREGATE public.myaggp09a(integer) OWNER TO ashutoshpg;

--
-- Name: myaggp09b(integer); Type: AGGREGATE; Schema: public; Owner: ashutoshpg
--

CREATE AGGREGATE public.myaggp09b(integer) (
    SFUNC = public.tf1p,
    STYPE = integer[],
    INITCOND = '{}'
);


ALTER AGGREGATE public.myaggp09b(integer) OWNER TO ashutoshpg;

--
-- Name: myaggp10a(integer); Type: AGGREGATE; Schema: public; Owner: ashutoshpg
--

CREATE AGGREGATE public.myaggp10a(integer) (
    SFUNC = public.tfp,
    STYPE = integer[],
    INITCOND = '{}',
    FINALFUNC = public.ffp
);


ALTER AGGREGATE public.myaggp10a(integer) OWNER TO ashutoshpg;

--
-- Name: myaggp10b(integer); Type: AGGREGATE; Schema: public; Owner: ashutoshpg
--

CREATE AGGREGATE public.myaggp10b(integer) (
    SFUNC = public.tfp,
    STYPE = integer[],
    INITCOND = '{}'
);


ALTER AGGREGATE public.myaggp10b(integer) OWNER TO ashutoshpg;

--
-- Name: myaggp20a(anyelement); Type: AGGREGATE; Schema: public; Owner: ashutoshpg
--

CREATE AGGREGATE public.myaggp20a(anyelement) (
    SFUNC = public.tfp,
    STYPE = anyarray,
    INITCOND = '{}',
    FINALFUNC = public.ffp
);


ALTER AGGREGATE public.myaggp20a(anyelement) OWNER TO ashutoshpg;

--
-- Name: myaggp20b(anyelement); Type: AGGREGATE; Schema: public; Owner: ashutoshpg
--

CREATE AGGREGATE public.myaggp20b(anyelement) (
    SFUNC = public.tfp,
    STYPE = anyarray,
    INITCOND = '{}'
);


ALTER AGGREGATE public.myaggp20b(anyelement) OWNER TO ashutoshpg;

--
-- Name: mysum2(anyelement, anyelement); Type: AGGREGATE; Schema: public; Owner: ashutoshpg
--

CREATE AGGREGATE public.mysum2(anyelement, anyelement) (
    SFUNC = public.sum3,
    STYPE = anyelement,
    INITCOND = '0'
);


ALTER AGGREGATE public.mysum2(anyelement, anyelement) OWNER TO ashutoshpg;

--
-- Name: newavg(integer); Type: AGGREGATE; Schema: public; Owner: ashutoshpg
--

CREATE AGGREGATE public.newavg(integer) (
    SFUNC = int4_avg_accum,
    STYPE = bigint[],
    INITCOND = '{0,0}',
    FINALFUNC = int8_avg
);


ALTER AGGREGATE public.newavg(integer) OWNER TO ashutoshpg;

--
-- Name: newcnt(*); Type: AGGREGATE; Schema: public; Owner: ashutoshpg
--

CREATE AGGREGATE public.newcnt(*) (
    SFUNC = int8inc,
    STYPE = bigint,
    INITCOND = '0',
    PARALLEL = safe
);


ALTER AGGREGATE public.newcnt(*) OWNER TO ashutoshpg;

--
-- Name: AGGREGATE newcnt(*); Type: COMMENT; Schema: public; Owner: ashutoshpg
--

COMMENT ON AGGREGATE public.newcnt(*) IS 'an agg(*) comment';


--
-- Name: newcnt("any"); Type: AGGREGATE; Schema: public; Owner: ashutoshpg
--

CREATE AGGREGATE public.newcnt("any") (
    SFUNC = int8inc_any,
    STYPE = bigint,
    INITCOND = '0'
);


ALTER AGGREGATE public.newcnt("any") OWNER TO ashutoshpg;

--
-- Name: AGGREGATE newcnt("any"); Type: COMMENT; Schema: public; Owner: ashutoshpg
--

COMMENT ON AGGREGATE public.newcnt("any") IS 'an agg(any) comment';


--
-- Name: newsum(integer); Type: AGGREGATE; Schema: public; Owner: ashutoshpg
--

CREATE AGGREGATE public.newsum(integer) (
    SFUNC = int4pl,
    STYPE = integer,
    INITCOND = '0'
);


ALTER AGGREGATE public.newsum(integer) OWNER TO ashutoshpg;

--
-- Name: oldcnt(*); Type: AGGREGATE; Schema: public; Owner: ashutoshpg
--

CREATE AGGREGATE public.oldcnt(*) (
    SFUNC = int8inc,
    STYPE = bigint,
    INITCOND = '0'
);


ALTER AGGREGATE public.oldcnt(*) OWNER TO ashutoshpg;

--
-- Name: sum2(bigint, bigint); Type: AGGREGATE; Schema: public; Owner: ashutoshpg
--

CREATE AGGREGATE public.sum2(bigint, bigint) (
    SFUNC = public.sum3,
    STYPE = bigint,
    INITCOND = '0'
);


ALTER AGGREGATE public.sum2(bigint, bigint) OWNER TO ashutoshpg;

--
-- Name: sum_int_randomrestart(integer); Type: AGGREGATE; Schema: public; Owner: ashutoshpg
--

CREATE AGGREGATE public.sum_int_randomrestart(integer) (
    SFUNC = int4pl,
    STYPE = integer,
    MSFUNC = int4pl,
    MINVFUNC = public.sum_int_randrestart_minvfunc,
    MSTYPE = integer
);


ALTER AGGREGATE public.sum_int_randomrestart(integer) OWNER TO ashutoshpg;

--
-- Name: sumdouble(double precision); Type: AGGREGATE; Schema: public; Owner: ashutoshpg
--

CREATE AGGREGATE public.sumdouble(double precision) (
    SFUNC = float8pl,
    STYPE = double precision,
    MSFUNC = float8pl,
    MINVFUNC = float8mi,
    MSTYPE = double precision
);


ALTER AGGREGATE public.sumdouble(double precision) OWNER TO ashutoshpg;

--
-- Name: test_percentile_disc(double precision, anyelement); Type: AGGREGATE; Schema: public; Owner: ashutoshpg
--

CREATE AGGREGATE public.test_percentile_disc(double precision ORDER BY anyelement) (
    SFUNC = ordered_set_transition,
    STYPE = internal,
    FINALFUNC = percentile_disc_final,
    FINALFUNC_EXTRA
);


ALTER AGGREGATE public.test_percentile_disc(double precision ORDER BY anyelement) OWNER TO ashutoshpg;

--
-- Name: test_rank("any"); Type: AGGREGATE; Schema: public; Owner: ashutoshpg
--

CREATE AGGREGATE public.test_rank(VARIADIC "any" ORDER BY VARIADIC "any") (
    SFUNC = ordered_set_transition_multi,
    STYPE = internal,
    FINALFUNC = rank_final,
    FINALFUNC_EXTRA,
    HYPOTHETICAL
);


ALTER AGGREGATE public.test_rank(VARIADIC "any" ORDER BY VARIADIC "any") OWNER TO ashutoshpg;

--
-- Name: heap2; Type: ACCESS METHOD; Schema: -; Owner: -
--

CREATE ACCESS METHOD heap2 TYPE TABLE HANDLER heap_tableam_handler;


--
-- Name: !=-; Type: OPERATOR; Schema: public; Owner: ashutoshpg
--

CREATE OPERATOR public.!=- (
    FUNCTION = factorial,
    RIGHTARG = bigint
);


ALTER OPERATOR public.!=- (NONE, bigint) OWNER TO ashutoshpg;

--
-- Name: ##; Type: OPERATOR; Schema: public; Owner: ashutoshpg
--

CREATE OPERATOR public.## (
    FUNCTION = path_inter,
    LEFTARG = path,
    RIGHTARG = path,
    COMMUTATOR = OPERATOR(public.##)
);


ALTER OPERATOR public.## (path, path) OWNER TO ashutoshpg;

--
-- Name: #@%#; Type: OPERATOR; Schema: public; Owner: ashutoshpg
--

CREATE OPERATOR public.#@%# (
    FUNCTION = factorial,
    RIGHTARG = bigint
);


ALTER OPERATOR public.#@%# (NONE, bigint) OWNER TO ashutoshpg;

--
-- Name: <; Type: OPERATOR; Schema: public; Owner: ashutoshpg
--

CREATE OPERATOR public.< (
    FUNCTION = public.int8alias1lt,
    LEFTARG = public.int8alias1,
    RIGHTARG = public.int8alias1
);


ALTER OPERATOR public.< (public.int8alias1, public.int8alias1) OWNER TO ashutoshpg;

--
-- Name: <%; Type: OPERATOR; Schema: public; Owner: ashutoshpg
--

CREATE OPERATOR public.<% (
    FUNCTION = public.pt_in_widget,
    LEFTARG = point,
    RIGHTARG = public.widget,
    COMMUTATOR = OPERATOR(public.>%),
    NEGATOR = OPERATOR(public.>=%)
);


ALTER OPERATOR public.<% (point, public.widget) OWNER TO ashutoshpg;

--
-- Name: =; Type: OPERATOR; Schema: public; Owner: ashutoshpg
--

CREATE OPERATOR public.= (
    FUNCTION = public.int8alias1eq,
    LEFTARG = public.int8alias1,
    RIGHTARG = public.int8alias1,
    COMMUTATOR = OPERATOR(public.=),
    MERGES,
    RESTRICT = eqsel,
    JOIN = eqjoinsel
);


ALTER OPERATOR public.= (public.int8alias1, public.int8alias1) OWNER TO ashutoshpg;

--
-- Name: =; Type: OPERATOR; Schema: public; Owner: ashutoshpg
--

CREATE OPERATOR public.= (
    FUNCTION = public.int8alias2eq,
    LEFTARG = public.int8alias2,
    RIGHTARG = public.int8alias2,
    COMMUTATOR = OPERATOR(public.=),
    MERGES,
    RESTRICT = eqsel,
    JOIN = eqjoinsel
);


ALTER OPERATOR public.= (public.int8alias2, public.int8alias2) OWNER TO ashutoshpg;

--
-- Name: =; Type: OPERATOR; Schema: public; Owner: ashutoshpg
--

CREATE OPERATOR public.= (
    FUNCTION = public.int8alias1eq,
    LEFTARG = bigint,
    RIGHTARG = public.int8alias1,
    MERGES,
    RESTRICT = eqsel,
    JOIN = eqjoinsel
);


ALTER OPERATOR public.= (bigint, public.int8alias1) OWNER TO ashutoshpg;

--
-- Name: =; Type: OPERATOR; Schema: public; Owner: ashutoshpg
--

CREATE OPERATOR public.= (
    FUNCTION = public.int8alias1eq,
    LEFTARG = public.int8alias1,
    RIGHTARG = public.int8alias2,
    MERGES,
    RESTRICT = eqsel,
    JOIN = eqjoinsel
);


ALTER OPERATOR public.= (public.int8alias1, public.int8alias2) OWNER TO ashutoshpg;

--
-- Name: @#@; Type: OPERATOR; Schema: public; Owner: ashutoshpg
--

CREATE OPERATOR public.@#@ (
    FUNCTION = factorial,
    RIGHTARG = bigint
);


ALTER OPERATOR public.@#@ (NONE, bigint) OWNER TO ashutoshpg;

--
-- Name: |@|; Type: OPERATOR; Schema: public; Owner: ashutoshpg
--

CREATE OPERATOR public.|@| (
    FUNCTION = unnest,
    RIGHTARG = anyarray
);


ALTER OPERATOR public.|@| (NONE, anyarray) OWNER TO ashutoshpg;

--
-- Name: at_test_sql_partop; Type: OPERATOR FAMILY; Schema: public; Owner: ashutoshpg
--

CREATE OPERATOR FAMILY public.at_test_sql_partop USING btree;


ALTER OPERATOR FAMILY public.at_test_sql_partop USING btree OWNER TO ashutoshpg;

--
-- Name: custom_opclass; Type: OPERATOR FAMILY; Schema: public; Owner: ashutoshpg
--

CREATE OPERATOR FAMILY public.custom_opclass USING hash;


ALTER OPERATOR FAMILY public.custom_opclass USING hash OWNER TO ashutoshpg;

--
-- Name: evttrigopclass; Type: OPERATOR FAMILY; Schema: public; Owner: ashutoshpg
--

CREATE OPERATOR FAMILY public.evttrigopclass USING btree;


ALTER OPERATOR FAMILY public.evttrigopclass USING btree OWNER TO ashutoshpg;

--
-- Name: evttrigopclass; Type: OPERATOR CLASS; Schema: public; Owner: ashutoshpg
--

CREATE OPERATOR CLASS public.evttrigopclass
    FOR TYPE integer USING btree FAMILY public.evttrigopclass AS
    STORAGE integer;


ALTER OPERATOR CLASS public.evttrigopclass USING btree OWNER TO ashutoshpg;

--
-- Name: part_test_int4_ops; Type: OPERATOR FAMILY; Schema: public; Owner: ashutoshpg
--

CREATE OPERATOR FAMILY public.part_test_int4_ops USING hash;
ALTER OPERATOR FAMILY public.part_test_int4_ops USING hash ADD
    FUNCTION 2 (integer, integer) public.part_hashint4_noop(integer,bigint);


ALTER OPERATOR FAMILY public.part_test_int4_ops USING hash OWNER TO ashutoshpg;

--
-- Name: part_test_int4_ops; Type: OPERATOR CLASS; Schema: public; Owner: ashutoshpg
--

CREATE OPERATOR CLASS public.part_test_int4_ops
    FOR TYPE integer USING hash FAMILY public.part_test_int4_ops AS
    OPERATOR 1 =(integer,integer);


ALTER OPERATOR CLASS public.part_test_int4_ops USING hash OWNER TO ashutoshpg;

--
-- Name: part_test_int4_ops2; Type: OPERATOR FAMILY; Schema: public; Owner: ashutoshpg
--

CREATE OPERATOR FAMILY public.part_test_int4_ops2 USING hash;
ALTER OPERATOR FAMILY public.part_test_int4_ops2 USING hash ADD
    FUNCTION 2 (integer, integer) public.part_hashint4_noop(integer,bigint);


ALTER OPERATOR FAMILY public.part_test_int4_ops2 USING hash OWNER TO ashutoshpg;

--
-- Name: part_test_text_ops; Type: OPERATOR FAMILY; Schema: public; Owner: ashutoshpg
--

CREATE OPERATOR FAMILY public.part_test_text_ops USING hash;
ALTER OPERATOR FAMILY public.part_test_text_ops USING hash ADD
    FUNCTION 2 (text, text) public.part_hashtext_length(text,bigint);


ALTER OPERATOR FAMILY public.part_test_text_ops USING hash OWNER TO ashutoshpg;

--
-- Name: part_test_text_ops; Type: OPERATOR CLASS; Schema: public; Owner: ashutoshpg
--

CREATE OPERATOR CLASS public.part_test_text_ops
    FOR TYPE text USING hash FAMILY public.part_test_text_ops AS
    OPERATOR 1 =(text,text);


ALTER OPERATOR CLASS public.part_test_text_ops USING hash OWNER TO ashutoshpg;

--
-- Name: test_int4_ops; Type: OPERATOR FAMILY; Schema: public; Owner: ashutoshpg
--

CREATE OPERATOR FAMILY public.test_int4_ops USING btree;


ALTER OPERATOR FAMILY public.test_int4_ops USING btree OWNER TO ashutoshpg;

--
-- Name: hunspell; Type: TEXT SEARCH DICTIONARY; Schema: public; Owner: ashutoshpg
--

CREATE TEXT SEARCH DICTIONARY public.hunspell (
    TEMPLATE = pg_catalog.ispell,
    dictfile = 'ispell_sample', afffile = 'hunspell_sample' );


ALTER TEXT SEARCH DICTIONARY public.hunspell OWNER TO ashutoshpg;

--
-- Name: hunspell_invalid_1; Type: TEXT SEARCH DICTIONARY; Schema: public; Owner: ashutoshpg
--

CREATE TEXT SEARCH DICTIONARY public.hunspell_invalid_1 (
    TEMPLATE = pg_catalog.ispell,
    dictfile = 'hunspell_sample_long', afffile = 'ispell_sample' );


ALTER TEXT SEARCH DICTIONARY public.hunspell_invalid_1 OWNER TO ashutoshpg;

--
-- Name: hunspell_invalid_2; Type: TEXT SEARCH DICTIONARY; Schema: public; Owner: ashutoshpg
--

CREATE TEXT SEARCH DICTIONARY public.hunspell_invalid_2 (
    TEMPLATE = pg_catalog.ispell,
    dictfile = 'hunspell_sample_long', afffile = 'hunspell_sample_num' );


ALTER TEXT SEARCH DICTIONARY public.hunspell_invalid_2 OWNER TO ashutoshpg;

--
-- Name: hunspell_invalid_3; Type: TEXT SEARCH DICTIONARY; Schema: public; Owner: ashutoshpg
--

CREATE TEXT SEARCH DICTIONARY public.hunspell_invalid_3 (
    TEMPLATE = pg_catalog.ispell,
    dictfile = 'hunspell_sample_num', afffile = 'ispell_sample' );


ALTER TEXT SEARCH DICTIONARY public.hunspell_invalid_3 OWNER TO ashutoshpg;

--
-- Name: hunspell_long; Type: TEXT SEARCH DICTIONARY; Schema: public; Owner: ashutoshpg
--

CREATE TEXT SEARCH DICTIONARY public.hunspell_long (
    TEMPLATE = pg_catalog.ispell,
    dictfile = 'hunspell_sample_long', afffile = 'hunspell_sample_long' );


ALTER TEXT SEARCH DICTIONARY public.hunspell_long OWNER TO ashutoshpg;

--
-- Name: hunspell_num; Type: TEXT SEARCH DICTIONARY; Schema: public; Owner: ashutoshpg
--

CREATE TEXT SEARCH DICTIONARY public.hunspell_num (
    TEMPLATE = pg_catalog.ispell,
    dictfile = 'hunspell_sample_num', afffile = 'hunspell_sample_num' );


ALTER TEXT SEARCH DICTIONARY public.hunspell_num OWNER TO ashutoshpg;

--
-- Name: ispell; Type: TEXT SEARCH DICTIONARY; Schema: public; Owner: ashutoshpg
--

CREATE TEXT SEARCH DICTIONARY public.ispell (
    TEMPLATE = pg_catalog.ispell,
    dictfile = 'ispell_sample', afffile = 'ispell_sample' );


ALTER TEXT SEARCH DICTIONARY public.ispell OWNER TO ashutoshpg;

--
-- Name: synonym; Type: TEXT SEARCH DICTIONARY; Schema: public; Owner: ashutoshpg
--

CREATE TEXT SEARCH DICTIONARY public.synonym (
    TEMPLATE = pg_catalog.synonym,
    synonyms = 'synonym_sample', casesensitive = 'off' );


ALTER TEXT SEARCH DICTIONARY public.synonym OWNER TO ashutoshpg;

--
-- Name: thesaurus; Type: TEXT SEARCH DICTIONARY; Schema: public; Owner: ashutoshpg
--

CREATE TEXT SEARCH DICTIONARY public.thesaurus (
    TEMPLATE = pg_catalog.thesaurus,
    dictfile = 'thesaurus_sample', dictionary = 'english_stem' );


ALTER TEXT SEARCH DICTIONARY public.thesaurus OWNER TO ashutoshpg;

--
-- Name: hunspell_tst; Type: TEXT SEARCH CONFIGURATION; Schema: public; Owner: ashutoshpg
--

CREATE TEXT SEARCH CONFIGURATION public.hunspell_tst (
    PARSER = pg_catalog."default" );

ALTER TEXT SEARCH CONFIGURATION public.hunspell_tst
    ADD MAPPING FOR asciiword WITH public.hunspell_num, english_stem;

ALTER TEXT SEARCH CONFIGURATION public.hunspell_tst
    ADD MAPPING FOR word WITH public.hunspell_num, english_stem;

ALTER TEXT SEARCH CONFIGURATION public.hunspell_tst
    ADD MAPPING FOR numword WITH public.hunspell_num, english_stem;

ALTER TEXT SEARCH CONFIGURATION public.hunspell_tst
    ADD MAPPING FOR email WITH simple;

ALTER TEXT SEARCH CONFIGURATION public.hunspell_tst
    ADD MAPPING FOR url WITH simple;

ALTER TEXT SEARCH CONFIGURATION public.hunspell_tst
    ADD MAPPING FOR host WITH simple;

ALTER TEXT SEARCH CONFIGURATION public.hunspell_tst
    ADD MAPPING FOR sfloat WITH simple;

ALTER TEXT SEARCH CONFIGURATION public.hunspell_tst
    ADD MAPPING FOR version WITH simple;

ALTER TEXT SEARCH CONFIGURATION public.hunspell_tst
    ADD MAPPING FOR hword_numpart WITH public.hunspell_num, english_stem;

ALTER TEXT SEARCH CONFIGURATION public.hunspell_tst
    ADD MAPPING FOR hword_part WITH public.hunspell_num, english_stem;

ALTER TEXT SEARCH CONFIGURATION public.hunspell_tst
    ADD MAPPING FOR hword_asciipart WITH public.hunspell_num, english_stem;

ALTER TEXT SEARCH CONFIGURATION public.hunspell_tst
    ADD MAPPING FOR numhword WITH public.hunspell_num, english_stem;

ALTER TEXT SEARCH CONFIGURATION public.hunspell_tst
    ADD MAPPING FOR asciihword WITH public.hunspell_num, english_stem;

ALTER TEXT SEARCH CONFIGURATION public.hunspell_tst
    ADD MAPPING FOR hword WITH public.hunspell_num, english_stem;

ALTER TEXT SEARCH CONFIGURATION public.hunspell_tst
    ADD MAPPING FOR url_path WITH simple;

ALTER TEXT SEARCH CONFIGURATION public.hunspell_tst
    ADD MAPPING FOR file WITH simple;

ALTER TEXT SEARCH CONFIGURATION public.hunspell_tst
    ADD MAPPING FOR "float" WITH simple;

ALTER TEXT SEARCH CONFIGURATION public.hunspell_tst
    ADD MAPPING FOR "int" WITH simple;

ALTER TEXT SEARCH CONFIGURATION public.hunspell_tst
    ADD MAPPING FOR uint WITH simple;


ALTER TEXT SEARCH CONFIGURATION public.hunspell_tst OWNER TO ashutoshpg;

--
-- Name: ispell_tst; Type: TEXT SEARCH CONFIGURATION; Schema: public; Owner: ashutoshpg
--

CREATE TEXT SEARCH CONFIGURATION public.ispell_tst (
    PARSER = pg_catalog."default" );

ALTER TEXT SEARCH CONFIGURATION public.ispell_tst
    ADD MAPPING FOR asciiword WITH public.ispell, english_stem;

ALTER TEXT SEARCH CONFIGURATION public.ispell_tst
    ADD MAPPING FOR word WITH public.ispell, english_stem;

ALTER TEXT SEARCH CONFIGURATION public.ispell_tst
    ADD MAPPING FOR numword WITH public.ispell, english_stem;

ALTER TEXT SEARCH CONFIGURATION public.ispell_tst
    ADD MAPPING FOR email WITH simple;

ALTER TEXT SEARCH CONFIGURATION public.ispell_tst
    ADD MAPPING FOR url WITH simple;

ALTER TEXT SEARCH CONFIGURATION public.ispell_tst
    ADD MAPPING FOR host WITH simple;

ALTER TEXT SEARCH CONFIGURATION public.ispell_tst
    ADD MAPPING FOR sfloat WITH simple;

ALTER TEXT SEARCH CONFIGURATION public.ispell_tst
    ADD MAPPING FOR version WITH simple;

ALTER TEXT SEARCH CONFIGURATION public.ispell_tst
    ADD MAPPING FOR hword_numpart WITH public.ispell, english_stem;

ALTER TEXT SEARCH CONFIGURATION public.ispell_tst
    ADD MAPPING FOR hword_part WITH public.ispell, english_stem;

ALTER TEXT SEARCH CONFIGURATION public.ispell_tst
    ADD MAPPING FOR hword_asciipart WITH public.ispell, english_stem;

ALTER TEXT SEARCH CONFIGURATION public.ispell_tst
    ADD MAPPING FOR numhword WITH public.ispell, english_stem;

ALTER TEXT SEARCH CONFIGURATION public.ispell_tst
    ADD MAPPING FOR asciihword WITH public.ispell, english_stem;

ALTER TEXT SEARCH CONFIGURATION public.ispell_tst
    ADD MAPPING FOR hword WITH public.ispell, english_stem;

ALTER TEXT SEARCH CONFIGURATION public.ispell_tst
    ADD MAPPING FOR url_path WITH simple;

ALTER TEXT SEARCH CONFIGURATION public.ispell_tst
    ADD MAPPING FOR file WITH simple;

ALTER TEXT SEARCH CONFIGURATION public.ispell_tst
    ADD MAPPING FOR "float" WITH simple;

ALTER TEXT SEARCH CONFIGURATION public.ispell_tst
    ADD MAPPING FOR "int" WITH simple;

ALTER TEXT SEARCH CONFIGURATION public.ispell_tst
    ADD MAPPING FOR uint WITH simple;


ALTER TEXT SEARCH CONFIGURATION public.ispell_tst OWNER TO ashutoshpg;

--
-- Name: synonym_tst; Type: TEXT SEARCH CONFIGURATION; Schema: public; Owner: ashutoshpg
--

CREATE TEXT SEARCH CONFIGURATION public.synonym_tst (
    PARSER = pg_catalog."default" );

ALTER TEXT SEARCH CONFIGURATION public.synonym_tst
    ADD MAPPING FOR asciiword WITH public.synonym, english_stem;

ALTER TEXT SEARCH CONFIGURATION public.synonym_tst
    ADD MAPPING FOR word WITH english_stem;

ALTER TEXT SEARCH CONFIGURATION public.synonym_tst
    ADD MAPPING FOR numword WITH simple;

ALTER TEXT SEARCH CONFIGURATION public.synonym_tst
    ADD MAPPING FOR email WITH simple;

ALTER TEXT SEARCH CONFIGURATION public.synonym_tst
    ADD MAPPING FOR url WITH simple;

ALTER TEXT SEARCH CONFIGURATION public.synonym_tst
    ADD MAPPING FOR host WITH simple;

ALTER TEXT SEARCH CONFIGURATION public.synonym_tst
    ADD MAPPING FOR sfloat WITH simple;

ALTER TEXT SEARCH CONFIGURATION public.synonym_tst
    ADD MAPPING FOR version WITH simple;

ALTER TEXT SEARCH CONFIGURATION public.synonym_tst
    ADD MAPPING FOR hword_numpart WITH simple;

ALTER TEXT SEARCH CONFIGURATION public.synonym_tst
    ADD MAPPING FOR hword_part WITH english_stem;

ALTER TEXT SEARCH CONFIGURATION public.synonym_tst
    ADD MAPPING FOR hword_asciipart WITH public.synonym, english_stem;

ALTER TEXT SEARCH CONFIGURATION public.synonym_tst
    ADD MAPPING FOR numhword WITH simple;

ALTER TEXT SEARCH CONFIGURATION public.synonym_tst
    ADD MAPPING FOR asciihword WITH public.synonym, english_stem;

ALTER TEXT SEARCH CONFIGURATION public.synonym_tst
    ADD MAPPING FOR hword WITH english_stem;

ALTER TEXT SEARCH CONFIGURATION public.synonym_tst
    ADD MAPPING FOR url_path WITH simple;

ALTER TEXT SEARCH CONFIGURATION public.synonym_tst
    ADD MAPPING FOR file WITH simple;

ALTER TEXT SEARCH CONFIGURATION public.synonym_tst
    ADD MAPPING FOR "float" WITH simple;

ALTER TEXT SEARCH CONFIGURATION public.synonym_tst
    ADD MAPPING FOR "int" WITH simple;

ALTER TEXT SEARCH CONFIGURATION public.synonym_tst
    ADD MAPPING FOR uint WITH simple;


ALTER TEXT SEARCH CONFIGURATION public.synonym_tst OWNER TO ashutoshpg;

--
-- Name: thesaurus_tst; Type: TEXT SEARCH CONFIGURATION; Schema: public; Owner: ashutoshpg
--

CREATE TEXT SEARCH CONFIGURATION public.thesaurus_tst (
    PARSER = pg_catalog."default" );

ALTER TEXT SEARCH CONFIGURATION public.thesaurus_tst
    ADD MAPPING FOR asciiword WITH public.synonym, public.thesaurus, english_stem;

ALTER TEXT SEARCH CONFIGURATION public.thesaurus_tst
    ADD MAPPING FOR word WITH english_stem;

ALTER TEXT SEARCH CONFIGURATION public.thesaurus_tst
    ADD MAPPING FOR numword WITH simple;

ALTER TEXT SEARCH CONFIGURATION public.thesaurus_tst
    ADD MAPPING FOR email WITH simple;

ALTER TEXT SEARCH CONFIGURATION public.thesaurus_tst
    ADD MAPPING FOR url WITH simple;

ALTER TEXT SEARCH CONFIGURATION public.thesaurus_tst
    ADD MAPPING FOR host WITH simple;

ALTER TEXT SEARCH CONFIGURATION public.thesaurus_tst
    ADD MAPPING FOR sfloat WITH simple;

ALTER TEXT SEARCH CONFIGURATION public.thesaurus_tst
    ADD MAPPING FOR version WITH simple;

ALTER TEXT SEARCH CONFIGURATION public.thesaurus_tst
    ADD MAPPING FOR hword_numpart WITH simple;

ALTER TEXT SEARCH CONFIGURATION public.thesaurus_tst
    ADD MAPPING FOR hword_part WITH english_stem;

ALTER TEXT SEARCH CONFIGURATION public.thesaurus_tst
    ADD MAPPING FOR hword_asciipart WITH public.synonym, public.thesaurus, english_stem;

ALTER TEXT SEARCH CONFIGURATION public.thesaurus_tst
    ADD MAPPING FOR numhword WITH simple;

ALTER TEXT SEARCH CONFIGURATION public.thesaurus_tst
    ADD MAPPING FOR asciihword WITH public.synonym, public.thesaurus, english_stem;

ALTER TEXT SEARCH CONFIGURATION public.thesaurus_tst
    ADD MAPPING FOR hword WITH english_stem;

ALTER TEXT SEARCH CONFIGURATION public.thesaurus_tst
    ADD MAPPING FOR url_path WITH simple;

ALTER TEXT SEARCH CONFIGURATION public.thesaurus_tst
    ADD MAPPING FOR file WITH simple;

ALTER TEXT SEARCH CONFIGURATION public.thesaurus_tst
    ADD MAPPING FOR "float" WITH simple;

ALTER TEXT SEARCH CONFIGURATION public.thesaurus_tst
    ADD MAPPING FOR "int" WITH simple;

ALTER TEXT SEARCH CONFIGURATION public.thesaurus_tst
    ADD MAPPING FOR uint WITH simple;


ALTER TEXT SEARCH CONFIGURATION public.thesaurus_tst OWNER TO ashutoshpg;

--
-- Name: useless; Type: FOREIGN DATA WRAPPER; Schema: -; Owner: ashutoshpg
--

CREATE FOREIGN DATA WRAPPER useless;


ALTER FOREIGN DATA WRAPPER useless OWNER TO ashutoshpg;

--
-- Name: useless_server; Type: SERVER; Schema: -; Owner: ashutoshpg
--

CREATE SERVER useless_server FOREIGN DATA WRAPPER useless;


ALTER SERVER useless_server OWNER TO ashutoshpg;

--
-- Name: fk; Type: TABLE; Schema: fkpart3; Owner: ashutoshpg
--

CREATE TABLE fkpart3.fk (
    a integer
)
PARTITION BY RANGE (a);


ALTER TABLE fkpart3.fk OWNER TO ashutoshpg;

--
-- Name: fk1; Type: TABLE; Schema: fkpart3; Owner: ashutoshpg
--

CREATE TABLE fkpart3.fk1 (
    a integer
);


ALTER TABLE fkpart3.fk1 OWNER TO ashutoshpg;

--
-- Name: fk2; Type: TABLE; Schema: fkpart3; Owner: ashutoshpg
--

CREATE TABLE fkpart3.fk2 (
    a integer
);


ALTER TABLE fkpart3.fk2 OWNER TO ashutoshpg;

--
-- Name: fk3; Type: TABLE; Schema: fkpart3; Owner: ashutoshpg
--

CREATE TABLE fkpart3.fk3 (
    a integer
);


ALTER TABLE fkpart3.fk3 OWNER TO ashutoshpg;

--
-- Name: pk; Type: TABLE; Schema: fkpart3; Owner: ashutoshpg
--

CREATE TABLE fkpart3.pk (
    a integer NOT NULL
)
PARTITION BY RANGE (a);


ALTER TABLE fkpart3.pk OWNER TO ashutoshpg;

--
-- Name: pk1; Type: TABLE; Schema: fkpart3; Owner: ashutoshpg
--

CREATE TABLE fkpart3.pk1 (
    a integer CONSTRAINT pk_a_not_null NOT NULL
);


ALTER TABLE fkpart3.pk1 OWNER TO ashutoshpg;

--
-- Name: pk2; Type: TABLE; Schema: fkpart3; Owner: ashutoshpg
--

CREATE TABLE fkpart3.pk2 (
    a integer NOT NULL
);


ALTER TABLE fkpart3.pk2 OWNER TO ashutoshpg;

--
-- Name: pk3; Type: TABLE; Schema: fkpart3; Owner: ashutoshpg
--

CREATE TABLE fkpart3.pk3 (
    a integer CONSTRAINT pk_a_not_null NOT NULL
);


ALTER TABLE fkpart3.pk3 OWNER TO ashutoshpg;

--
-- Name: pk4; Type: TABLE; Schema: fkpart3; Owner: ashutoshpg
--

CREATE TABLE fkpart3.pk4 (
    a integer CONSTRAINT pk_a_not_null NOT NULL
);


ALTER TABLE fkpart3.pk4 OWNER TO ashutoshpg;

--
-- Name: pk5; Type: TABLE; Schema: fkpart3; Owner: ashutoshpg
--

CREATE TABLE fkpart3.pk5 (
    a integer NOT NULL
)
PARTITION BY RANGE (a);


ALTER TABLE fkpart3.pk5 OWNER TO ashutoshpg;

--
-- Name: pk51; Type: TABLE; Schema: fkpart3; Owner: ashutoshpg
--

CREATE TABLE fkpart3.pk51 (
    a integer CONSTRAINT pk5_a_not_null NOT NULL
);


ALTER TABLE fkpart3.pk51 OWNER TO ashutoshpg;

--
-- Name: pk52; Type: TABLE; Schema: fkpart3; Owner: ashutoshpg
--

CREATE TABLE fkpart3.pk52 (
    a integer CONSTRAINT pk5_a_not_null NOT NULL
);


ALTER TABLE fkpart3.pk52 OWNER TO ashutoshpg;

--
-- Name: dropfk; Type: TABLE; Schema: fkpart4; Owner: ashutoshpg
--

CREATE TABLE fkpart4.dropfk (
    a integer
);


ALTER TABLE fkpart4.dropfk OWNER TO ashutoshpg;

--
-- Name: droppk; Type: TABLE; Schema: fkpart4; Owner: ashutoshpg
--

CREATE TABLE fkpart4.droppk (
    a integer NOT NULL
)
PARTITION BY RANGE (a);


ALTER TABLE fkpart4.droppk OWNER TO ashutoshpg;

--
-- Name: droppk1; Type: TABLE; Schema: fkpart4; Owner: ashutoshpg
--

CREATE TABLE fkpart4.droppk1 (
    a integer CONSTRAINT droppk_a_not_null NOT NULL
);


ALTER TABLE fkpart4.droppk1 OWNER TO ashutoshpg;

--
-- Name: droppk2; Type: TABLE; Schema: fkpart4; Owner: ashutoshpg
--

CREATE TABLE fkpart4.droppk2 (
    a integer CONSTRAINT droppk_a_not_null NOT NULL
)
PARTITION BY RANGE (a);


ALTER TABLE fkpart4.droppk2 OWNER TO ashutoshpg;

--
-- Name: droppk21; Type: TABLE; Schema: fkpart4; Owner: ashutoshpg
--

CREATE TABLE fkpart4.droppk21 (
    a integer CONSTRAINT droppk_a_not_null NOT NULL
);


ALTER TABLE fkpart4.droppk21 OWNER TO ashutoshpg;

--
-- Name: droppk2_d; Type: TABLE; Schema: fkpart4; Owner: ashutoshpg
--

CREATE TABLE fkpart4.droppk2_d (
    a integer CONSTRAINT droppk_a_not_null NOT NULL
);


ALTER TABLE fkpart4.droppk2_d OWNER TO ashutoshpg;

--
-- Name: droppk_d; Type: TABLE; Schema: fkpart4; Owner: ashutoshpg
--

CREATE TABLE fkpart4.droppk_d (
    a integer CONSTRAINT droppk_a_not_null NOT NULL
);


ALTER TABLE fkpart4.droppk_d OWNER TO ashutoshpg;

--
-- Name: fk; Type: TABLE; Schema: fkpart5; Owner: ashutoshpg
--

CREATE TABLE fkpart5.fk (
    a integer
)
PARTITION BY LIST (a);


ALTER TABLE fkpart5.fk OWNER TO ashutoshpg;

--
-- Name: fk1; Type: TABLE; Schema: fkpart5; Owner: ashutoshpg
--

CREATE TABLE fkpart5.fk1 (
    a integer
)
PARTITION BY LIST (a);


ALTER TABLE fkpart5.fk1 OWNER TO ashutoshpg;

--
-- Name: fk11; Type: TABLE; Schema: fkpart5; Owner: ashutoshpg
--

CREATE TABLE fkpart5.fk11 (
    a integer
);


ALTER TABLE fkpart5.fk11 OWNER TO ashutoshpg;

--
-- Name: fk2; Type: TABLE; Schema: fkpart5; Owner: ashutoshpg
--

CREATE TABLE fkpart5.fk2 (
    a integer
);


ALTER TABLE fkpart5.fk2 OWNER TO ashutoshpg;

--
-- Name: fk3; Type: TABLE; Schema: fkpart5; Owner: ashutoshpg
--

CREATE TABLE fkpart5.fk3 (
    a integer
);


ALTER TABLE fkpart5.fk3 OWNER TO ashutoshpg;

--
-- Name: fk4; Type: TABLE; Schema: fkpart5; Owner: ashutoshpg
--

CREATE TABLE fkpart5.fk4 (
    a integer
);


ALTER TABLE fkpart5.fk4 OWNER TO ashutoshpg;

--
-- Name: pk; Type: TABLE; Schema: fkpart5; Owner: ashutoshpg
--

CREATE TABLE fkpart5.pk (
    a integer NOT NULL
)
PARTITION BY LIST (a);


ALTER TABLE fkpart5.pk OWNER TO ashutoshpg;

--
-- Name: pk1; Type: TABLE; Schema: fkpart5; Owner: ashutoshpg
--

CREATE TABLE fkpart5.pk1 (
    a integer CONSTRAINT pk_a_not_null NOT NULL
)
PARTITION BY LIST (a);


ALTER TABLE fkpart5.pk1 OWNER TO ashutoshpg;

--
-- Name: pk11; Type: TABLE; Schema: fkpart5; Owner: ashutoshpg
--

CREATE TABLE fkpart5.pk11 (
    a integer CONSTRAINT pk_a_not_null NOT NULL
);


ALTER TABLE fkpart5.pk11 OWNER TO ashutoshpg;

--
-- Name: pk2; Type: TABLE; Schema: fkpart5; Owner: ashutoshpg
--

CREATE TABLE fkpart5.pk2 (
    a integer CONSTRAINT pk_a_not_null NOT NULL
);


ALTER TABLE fkpart5.pk2 OWNER TO ashutoshpg;

--
-- Name: pk3; Type: TABLE; Schema: fkpart5; Owner: ashutoshpg
--

CREATE TABLE fkpart5.pk3 (
    a integer NOT NULL
)
PARTITION BY LIST (a);


ALTER TABLE fkpart5.pk3 OWNER TO ashutoshpg;

--
-- Name: pk31; Type: TABLE; Schema: fkpart5; Owner: ashutoshpg
--

CREATE TABLE fkpart5.pk31 (
    a integer CONSTRAINT pk3_a_not_null NOT NULL
);


ALTER TABLE fkpart5.pk31 OWNER TO ashutoshpg;

--
-- Name: pk32; Type: TABLE; Schema: fkpart5; Owner: ashutoshpg
--

CREATE TABLE fkpart5.pk32 (
    a integer NOT NULL
);


ALTER TABLE fkpart5.pk32 OWNER TO ashutoshpg;

--
-- Name: pk; Type: TABLE; Schema: fkpart6; Owner: ashutoshpg
--

CREATE TABLE fkpart6.pk (
    a integer NOT NULL
)
PARTITION BY RANGE (a);


ALTER TABLE fkpart6.pk OWNER TO ashutoshpg;

--
-- Name: pk1; Type: TABLE; Schema: fkpart6; Owner: ashutoshpg
--

CREATE TABLE fkpart6.pk1 (
    a integer CONSTRAINT pk_a_not_null NOT NULL
)
PARTITION BY RANGE (a);


ALTER TABLE fkpart6.pk1 OWNER TO ashutoshpg;

--
-- Name: pk11; Type: TABLE; Schema: fkpart6; Owner: ashutoshpg
--

CREATE TABLE fkpart6.pk11 (
    a integer CONSTRAINT pk_a_not_null NOT NULL
);


ALTER TABLE fkpart6.pk11 OWNER TO ashutoshpg;

--
-- Name: pk12; Type: TABLE; Schema: fkpart6; Owner: ashutoshpg
--

CREATE TABLE fkpart6.pk12 (
    a integer CONSTRAINT pk_a_not_null NOT NULL
);


ALTER TABLE fkpart6.pk12 OWNER TO ashutoshpg;

--
-- Name: gtest0; Type: TABLE; Schema: generated_stored_tests; Owner: ashutoshpg
--

CREATE TABLE generated_stored_tests.gtest0 (
    a integer NOT NULL,
    b integer GENERATED ALWAYS AS (55) STORED
);


ALTER TABLE generated_stored_tests.gtest0 OWNER TO ashutoshpg;

--
-- Name: gtest1; Type: TABLE; Schema: generated_stored_tests; Owner: ashutoshpg
--

CREATE TABLE generated_stored_tests.gtest1 (
    a integer NOT NULL,
    b integer GENERATED ALWAYS AS ((a * 2)) STORED
);


ALTER TABLE generated_stored_tests.gtest1 OWNER TO ashutoshpg;

--
-- Name: gtest10; Type: TABLE; Schema: generated_stored_tests; Owner: ashutoshpg
--

CREATE TABLE generated_stored_tests.gtest10 (
    a integer NOT NULL
);


ALTER TABLE generated_stored_tests.gtest10 OWNER TO ashutoshpg;

--
-- Name: gtest10a; Type: TABLE; Schema: generated_stored_tests; Owner: ashutoshpg
--

CREATE TABLE generated_stored_tests.gtest10a (
    a integer NOT NULL
);


ALTER TABLE generated_stored_tests.gtest10a OWNER TO ashutoshpg;

--
-- Name: gtest1_1; Type: TABLE; Schema: generated_stored_tests; Owner: ashutoshpg
--

CREATE TABLE generated_stored_tests.gtest1_1 (
)
INHERITS (generated_stored_tests.gtest1);


ALTER TABLE generated_stored_tests.gtest1_1 OWNER TO ashutoshpg;

--
-- Name: gtesty; Type: TABLE; Schema: generated_stored_tests; Owner: ashutoshpg
--

CREATE TABLE generated_stored_tests.gtesty (
    x integer,
    b integer GENERATED ALWAYS AS ((x * 22)) STORED
);


ALTER TABLE generated_stored_tests.gtesty OWNER TO ashutoshpg;

--
-- Name: gtest1_y; Type: TABLE; Schema: generated_stored_tests; Owner: ashutoshpg
--

CREATE TABLE generated_stored_tests.gtest1_y (
    b integer GENERATED ALWAYS AS ((x + 1)) STORED
)
INHERITS (generated_stored_tests.gtest1, generated_stored_tests.gtesty);


ALTER TABLE generated_stored_tests.gtest1_y OWNER TO ashutoshpg;

--
-- Name: gtest2; Type: TABLE; Schema: generated_stored_tests; Owner: ashutoshpg
--

CREATE TABLE generated_stored_tests.gtest2 (
    a integer NOT NULL,
    b integer GENERATED ALWAYS AS (NULL::integer) STORED
);


ALTER TABLE generated_stored_tests.gtest2 OWNER TO ashutoshpg;

--
-- Name: gtest20; Type: TABLE; Schema: generated_stored_tests; Owner: ashutoshpg
--

CREATE TABLE generated_stored_tests.gtest20 (
    a integer NOT NULL,
    b integer GENERATED ALWAYS AS ((a * 3)) STORED,
    CONSTRAINT gtest20_b_check CHECK ((b < 50))
);


ALTER TABLE generated_stored_tests.gtest20 OWNER TO ashutoshpg;

--
-- Name: gtest20a; Type: TABLE; Schema: generated_stored_tests; Owner: ashutoshpg
--

CREATE TABLE generated_stored_tests.gtest20a (
    a integer NOT NULL,
    b integer GENERATED ALWAYS AS ((a * 2)) STORED
);


ALTER TABLE generated_stored_tests.gtest20a OWNER TO ashutoshpg;

--
-- Name: gtest20b; Type: TABLE; Schema: generated_stored_tests; Owner: ashutoshpg
--

CREATE TABLE generated_stored_tests.gtest20b (
    a integer NOT NULL,
    b integer GENERATED ALWAYS AS ((a * 2)) STORED
);


ALTER TABLE generated_stored_tests.gtest20b OWNER TO ashutoshpg;

--
-- Name: gtest21a; Type: TABLE; Schema: generated_stored_tests; Owner: ashutoshpg
--

CREATE TABLE generated_stored_tests.gtest21a (
    a integer NOT NULL,
    b integer GENERATED ALWAYS AS (NULLIF(a, 0)) STORED NOT NULL
);


ALTER TABLE generated_stored_tests.gtest21a OWNER TO ashutoshpg;

--
-- Name: gtest21b; Type: TABLE; Schema: generated_stored_tests; Owner: ashutoshpg
--

CREATE TABLE generated_stored_tests.gtest21b (
    a integer NOT NULL,
    b integer GENERATED ALWAYS AS (NULLIF(a, 0)) STORED
);


ALTER TABLE generated_stored_tests.gtest21b OWNER TO ashutoshpg;

--
-- Name: gtest22a; Type: TABLE; Schema: generated_stored_tests; Owner: ashutoshpg
--

CREATE TABLE generated_stored_tests.gtest22a (
    a integer NOT NULL,
    b integer GENERATED ALWAYS AS ((a / 2)) STORED
);


ALTER TABLE generated_stored_tests.gtest22a OWNER TO ashutoshpg;

--
-- Name: gtest22b; Type: TABLE; Schema: generated_stored_tests; Owner: ashutoshpg
--

CREATE TABLE generated_stored_tests.gtest22b (
    a integer NOT NULL,
    b integer GENERATED ALWAYS AS ((a / 2)) STORED NOT NULL
);


ALTER TABLE generated_stored_tests.gtest22b OWNER TO ashutoshpg;

--
-- Name: gtest22c; Type: TABLE; Schema: generated_stored_tests; Owner: ashutoshpg
--

CREATE TABLE generated_stored_tests.gtest22c (
    a integer,
    b integer GENERATED ALWAYS AS ((a * 4)) STORED
);


ALTER TABLE generated_stored_tests.gtest22c OWNER TO ashutoshpg;

--
-- Name: gtest23p; Type: TABLE; Schema: generated_stored_tests; Owner: ashutoshpg
--

CREATE TABLE generated_stored_tests.gtest23p (
    x integer,
    y integer GENERATED ALWAYS AS ((x * 2)) STORED NOT NULL
);


ALTER TABLE generated_stored_tests.gtest23p OWNER TO ashutoshpg;

--
-- Name: gtest23q; Type: TABLE; Schema: generated_stored_tests; Owner: ashutoshpg
--

CREATE TABLE generated_stored_tests.gtest23q (
    a integer NOT NULL,
    b integer
);


ALTER TABLE generated_stored_tests.gtest23q OWNER TO ashutoshpg;

--
-- Name: gtest24; Type: TABLE; Schema: generated_stored_tests; Owner: ashutoshpg
--

CREATE TABLE generated_stored_tests.gtest24 (
    a integer NOT NULL,
    b generated_stored_tests.gtestdomain1 GENERATED ALWAYS AS ((a * 2)) STORED
);


ALTER TABLE generated_stored_tests.gtest24 OWNER TO ashutoshpg;

--
-- Name: gtest25; Type: TABLE; Schema: generated_stored_tests; Owner: ashutoshpg
--

CREATE TABLE generated_stored_tests.gtest25 (
    a integer NOT NULL,
    b integer GENERATED ALWAYS AS ((a * 3)) STORED,
    c integer DEFAULT 42,
    x integer GENERATED ALWAYS AS ((c * 4)) STORED,
    d double precision DEFAULT 101,
    y double precision GENERATED ALWAYS AS ((d * (4)::double precision)) STORED
);


ALTER TABLE generated_stored_tests.gtest25 OWNER TO ashutoshpg;

--
-- Name: gtest26; Type: TABLE; Schema: generated_stored_tests; Owner: ashutoshpg
--

CREATE TABLE generated_stored_tests.gtest26 (
    a integer NOT NULL,
    b integer GENERATED ALWAYS AS ((a * 2)) STORED
);


ALTER TABLE generated_stored_tests.gtest26 OWNER TO ashutoshpg;

--
-- Name: gtest27; Type: TABLE; Schema: generated_stored_tests; Owner: ashutoshpg
--

CREATE TABLE generated_stored_tests.gtest27 (
    a bigint,
    b bigint,
    x bigint GENERATED ALWAYS AS (((a + b) * 2)) STORED
);


ALTER TABLE generated_stored_tests.gtest27 OWNER TO ashutoshpg;

--
-- Name: gtest28a; Type: TABLE; Schema: generated_stored_tests; Owner: ashutoshpg
--

CREATE TABLE generated_stored_tests.gtest28a (
    b integer,
    c integer,
    x integer GENERATED ALWAYS AS ((b * 2)) STORED
);


ALTER TABLE generated_stored_tests.gtest28a OWNER TO ashutoshpg;

--
-- Name: gtest28b; Type: TABLE; Schema: generated_stored_tests; Owner: ashutoshpg
--

CREATE TABLE generated_stored_tests.gtest28b (
    b integer,
    c integer,
    x integer GENERATED ALWAYS AS ((b * 2)) STORED
);


ALTER TABLE generated_stored_tests.gtest28b OWNER TO ashutoshpg;

--
-- Name: gtest29; Type: TABLE; Schema: generated_stored_tests; Owner: ashutoshpg
--

CREATE TABLE generated_stored_tests.gtest29 (
    b integer
);


ALTER TABLE generated_stored_tests.gtest29 OWNER TO ashutoshpg;

--
-- Name: gtest3; Type: TABLE; Schema: generated_stored_tests; Owner: ashutoshpg
--

CREATE TABLE generated_stored_tests.gtest3 (
    a integer,
    b integer GENERATED ALWAYS AS ((a * 3)) STORED
);


ALTER TABLE generated_stored_tests.gtest3 OWNER TO ashutoshpg;

--
-- Name: gtest30; Type: TABLE; Schema: generated_stored_tests; Owner: ashutoshpg
--

CREATE TABLE generated_stored_tests.gtest30 (
    a integer,
    b integer GENERATED ALWAYS AS ((a * 2)) STORED
);


ALTER TABLE generated_stored_tests.gtest30 OWNER TO ashutoshpg;

--
-- Name: gtest30_1; Type: TABLE; Schema: generated_stored_tests; Owner: ashutoshpg
--

CREATE TABLE generated_stored_tests.gtest30_1 (
)
INHERITS (generated_stored_tests.gtest30);


ALTER TABLE generated_stored_tests.gtest30_1 OWNER TO ashutoshpg;

--
-- Name: gtest3a; Type: TABLE; Schema: generated_stored_tests; Owner: ashutoshpg
--

CREATE TABLE generated_stored_tests.gtest3a (
    a text,
    b text GENERATED ALWAYS AS (((a || '+'::text) || a)) STORED
);


ALTER TABLE generated_stored_tests.gtest3a OWNER TO ashutoshpg;

--
-- Name: gtest_parent; Type: TABLE; Schema: generated_stored_tests; Owner: ashutoshpg
--

CREATE TABLE generated_stored_tests.gtest_parent (
    f1 date NOT NULL,
    f2 bigint,
    f3 bigint GENERATED ALWAYS AS ((f2 * 2)) STORED
)
PARTITION BY RANGE (f1);


ALTER TABLE generated_stored_tests.gtest_parent OWNER TO ashutoshpg;

--
-- Name: gtest_child; Type: TABLE; Schema: generated_stored_tests; Owner: ashutoshpg
--

CREATE TABLE generated_stored_tests.gtest_child (
    f1 date CONSTRAINT gtest_parent_f1_not_null NOT NULL,
    f2 bigint,
    f3 bigint GENERATED ALWAYS AS ((f2 * 2)) STORED
);


ALTER TABLE generated_stored_tests.gtest_child OWNER TO ashutoshpg;

--
-- Name: gtest_child2; Type: TABLE; Schema: generated_stored_tests; Owner: ashutoshpg
--

CREATE TABLE generated_stored_tests.gtest_child2 (
    f1 date CONSTRAINT gtest_parent_f1_not_null NOT NULL,
    f2 bigint,
    f3 bigint GENERATED ALWAYS AS ((f2 * 2)) STORED
);


ALTER TABLE generated_stored_tests.gtest_child2 OWNER TO ashutoshpg;

--
-- Name: gtest_child3; Type: TABLE; Schema: generated_stored_tests; Owner: ashutoshpg
--

CREATE TABLE generated_stored_tests.gtest_child3 (
    f1 date NOT NULL,
    f2 bigint,
    f3 bigint GENERATED ALWAYS AS ((f2 * 2)) STORED
);


ALTER TABLE generated_stored_tests.gtest_child3 OWNER TO ashutoshpg;

--
-- Name: gtest_tableoid; Type: TABLE; Schema: generated_stored_tests; Owner: ashutoshpg
--

CREATE TABLE generated_stored_tests.gtest_tableoid (
    a integer NOT NULL,
    b boolean GENERATED ALWAYS AS ((tableoid = ('generated_stored_tests.gtest_tableoid'::regclass)::oid)) STORED,
    c regclass GENERATED ALWAYS AS (tableoid) STORED
);


ALTER TABLE generated_stored_tests.gtest_tableoid OWNER TO ashutoshpg;

--
-- Name: gtestx; Type: TABLE; Schema: generated_stored_tests; Owner: ashutoshpg
--

CREATE TABLE generated_stored_tests.gtestx (
    b integer GENERATED ALWAYS AS ((a * 22)) STORED,
    x integer
)
INHERITS (generated_stored_tests.gtest1);


ALTER TABLE generated_stored_tests.gtestx OWNER TO ashutoshpg;

--
-- Name: gtestxx_1; Type: TABLE; Schema: generated_stored_tests; Owner: ashutoshpg
--

CREATE TABLE generated_stored_tests.gtestxx_1 (
    a integer NOT NULL,
    b integer
);


ALTER TABLE generated_stored_tests.gtestxx_1 OWNER TO ashutoshpg;

--
-- Name: gtestxx_3; Type: TABLE; Schema: generated_stored_tests; Owner: ashutoshpg
--

CREATE TABLE generated_stored_tests.gtestxx_3 (
    a integer NOT NULL,
    b integer
)
INHERITS (generated_stored_tests.gtest1);


ALTER TABLE generated_stored_tests.gtestxx_3 OWNER TO ashutoshpg;

--
-- Name: gtestxx_4; Type: TABLE; Schema: generated_stored_tests; Owner: ashutoshpg
--

CREATE TABLE generated_stored_tests.gtestxx_4 (
    b integer,
    a integer NOT NULL
)
INHERITS (generated_stored_tests.gtest1);


ALTER TABLE generated_stored_tests.gtestxx_4 OWNER TO ashutoshpg;

--
-- Name: mvtest_t; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.mvtest_t (
    id integer NOT NULL,
    type text NOT NULL,
    amt numeric NOT NULL
);


ALTER TABLE public.mvtest_t OWNER TO ashutoshpg;

--
-- Name: mvtest_tv; Type: VIEW; Schema: public; Owner: ashutoshpg
--

CREATE VIEW public.mvtest_tv AS
 SELECT type,
    sum(amt) AS totamt
   FROM public.mvtest_t
  GROUP BY type;


ALTER VIEW public.mvtest_tv OWNER TO ashutoshpg;

--
-- Name: mvtest_tvm; Type: MATERIALIZED VIEW; Schema: mvtest_mvschema; Owner: ashutoshpg
--

CREATE MATERIALIZED VIEW mvtest_mvschema.mvtest_tvm AS
 SELECT type,
    totamt
   FROM public.mvtest_tv
  ORDER BY type
  WITH NO DATA;


ALTER MATERIALIZED VIEW mvtest_mvschema.mvtest_tvm OWNER TO ashutoshpg;

--
-- Name: a; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.a (
    aa integer
);


ALTER TABLE public.a OWNER TO ashutoshpg;

--
-- Name: a_star; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.a_star (
    class character(1),
    aa integer,
    a text
);


ALTER TABLE public.a_star OWNER TO ashutoshpg;

--
-- Name: agg_data_20k; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.agg_data_20k (
    g integer
);


ALTER TABLE public.agg_data_20k OWNER TO ashutoshpg;

--
-- Name: agg_data_2k; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.agg_data_2k (
    g integer
);


ALTER TABLE public.agg_data_2k OWNER TO ashutoshpg;

--
-- Name: aggtest; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.aggtest (
    a smallint,
    b real
);


ALTER TABLE public.aggtest OWNER TO ashutoshpg;

--
-- Name: alpha; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.alpha (
    a double precision,
    b integer,
    c text
)
PARTITION BY RANGE (a);


ALTER TABLE public.alpha OWNER TO ashutoshpg;

--
-- Name: alpha_neg; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.alpha_neg (
    a double precision,
    b integer,
    c text
)
PARTITION BY RANGE (b);


ALTER TABLE public.alpha_neg OWNER TO ashutoshpg;

--
-- Name: alpha_neg_p1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.alpha_neg_p1 (
    a double precision,
    b integer,
    c text
);


ALTER TABLE public.alpha_neg_p1 OWNER TO ashutoshpg;

--
-- Name: alpha_neg_p2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.alpha_neg_p2 (
    a double precision,
    b integer,
    c text
);


ALTER TABLE public.alpha_neg_p2 OWNER TO ashutoshpg;

--
-- Name: alpha_neg_p3; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.alpha_neg_p3 (
    a double precision,
    b integer,
    c text
);


ALTER TABLE public.alpha_neg_p3 OWNER TO ashutoshpg;

--
-- Name: alpha_pos; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.alpha_pos (
    a double precision,
    b integer,
    c text
)
PARTITION BY LIST (c);


ALTER TABLE public.alpha_pos OWNER TO ashutoshpg;

--
-- Name: alpha_pos_p1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.alpha_pos_p1 (
    a double precision,
    b integer,
    c text
);


ALTER TABLE public.alpha_pos_p1 OWNER TO ashutoshpg;

--
-- Name: alpha_pos_p2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.alpha_pos_p2 (
    a double precision,
    b integer,
    c text
);


ALTER TABLE public.alpha_pos_p2 OWNER TO ashutoshpg;

--
-- Name: alpha_pos_p3; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.alpha_pos_p3 (
    a double precision,
    b integer,
    c text
);


ALTER TABLE public.alpha_pos_p3 OWNER TO ashutoshpg;

--
-- Name: alter_idx_rename_test_parted_2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.alter_idx_rename_test_parted_2 (
    a integer
)
PARTITION BY LIST (a);


ALTER TABLE public.alter_idx_rename_test_parted_2 OWNER TO ashutoshpg;

--
-- Name: alter_table_under_transition_tables; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.alter_table_under_transition_tables (
    id integer NOT NULL
);


ALTER TABLE public.alter_table_under_transition_tables OWNER TO ashutoshpg;

--
-- Name: array_index_op_test; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.array_index_op_test (
    seqno integer,
    i integer[],
    t text[]
);


ALTER TABLE public.array_index_op_test OWNER TO ashutoshpg;

--
-- Name: array_op_test; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.array_op_test (
    seqno integer,
    i integer[],
    t text[]
);


ALTER TABLE public.array_op_test OWNER TO ashutoshpg;

--
-- Name: arrtest; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.arrtest (
    a smallint[],
    b integer[],
    c name[],
    d text[],
    e double precision[],
    f character(5)[],
    g character varying(5)[]
);


ALTER TABLE public.arrtest OWNER TO ashutoshpg;

--
-- Name: atnotnull1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.atnotnull1 (
    a integer NOT NULL,
    b integer NOT NULL,
    c integer NOT NULL
);


ALTER TABLE public.atnotnull1 OWNER TO ashutoshpg;

--
-- Name: attach_parted; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.attach_parted (
    a integer,
    b integer
)
PARTITION BY LIST (b);


ALTER TABLE public.attach_parted OWNER TO ashutoshpg;

--
-- Name: attach_parted_part1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.attach_parted_part1 (
    a integer,
    b integer
);


ALTER TABLE public.attach_parted_part1 OWNER TO ashutoshpg;

--
-- Name: b; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.b (
    bb text
)
INHERITS (public.a);


ALTER TABLE public.b OWNER TO ashutoshpg;

--
-- Name: b_star; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.b_star (
    bb text
)
INHERITS (public.a_star);


ALTER TABLE public.b_star OWNER TO ashutoshpg;

--
-- Name: bar1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.bar1 (
    a integer,
    b integer DEFAULT 1 NOT NULL
)
PARTITION BY RANGE (a);


ALTER TABLE public.bar1 OWNER TO ashutoshpg;

--
-- Name: bar2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.bar2 (
    a integer,
    b integer DEFAULT 1 NOT NULL
);


ALTER TABLE public.bar2 OWNER TO ashutoshpg;

--
-- Name: beta; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.beta (
    a double precision,
    b integer,
    c text
)
PARTITION BY RANGE (a);


ALTER TABLE public.beta OWNER TO ashutoshpg;

--
-- Name: beta_neg; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.beta_neg (
    a double precision,
    b integer,
    c text
)
PARTITION BY RANGE (b);


ALTER TABLE public.beta_neg OWNER TO ashutoshpg;

--
-- Name: beta_neg_p1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.beta_neg_p1 (
    a double precision,
    b integer,
    c text
);


ALTER TABLE public.beta_neg_p1 OWNER TO ashutoshpg;

--
-- Name: beta_neg_p2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.beta_neg_p2 (
    a double precision,
    b integer,
    c text
);


ALTER TABLE public.beta_neg_p2 OWNER TO ashutoshpg;

--
-- Name: beta_neg_p3; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.beta_neg_p3 (
    a double precision,
    b integer,
    c text
);


ALTER TABLE public.beta_neg_p3 OWNER TO ashutoshpg;

--
-- Name: beta_pos; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.beta_pos (
    a double precision,
    b integer,
    c text
)
PARTITION BY LIST (c);


ALTER TABLE public.beta_pos OWNER TO ashutoshpg;

--
-- Name: beta_pos_p1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.beta_pos_p1 (
    a double precision,
    b integer,
    c text
);


ALTER TABLE public.beta_pos_p1 OWNER TO ashutoshpg;

--
-- Name: beta_pos_p2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.beta_pos_p2 (
    a double precision,
    b integer,
    c text
);


ALTER TABLE public.beta_pos_p2 OWNER TO ashutoshpg;

--
-- Name: beta_pos_p3; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.beta_pos_p3 (
    a double precision,
    b integer,
    c text
);


ALTER TABLE public.beta_pos_p3 OWNER TO ashutoshpg;

--
-- Name: big5_inputs; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.big5_inputs (
    inbytes bytea,
    description text
);


ALTER TABLE public.big5_inputs OWNER TO ashutoshpg;

--
-- Name: bit_defaults; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.bit_defaults (
    b1 bit(4) DEFAULT '1001'::"bit",
    b2 bit(4) DEFAULT '0101'::"bit",
    b3 bit varying(5) DEFAULT '1001'::bit varying,
    b4 bit varying(5) DEFAULT '0101'::"bit"
);


ALTER TABLE public.bit_defaults OWNER TO ashutoshpg;

--
-- Name: boolvalues; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.boolvalues (
    value boolean NOT NULL
);


ALTER TABLE public.boolvalues OWNER TO ashutoshpg;

--
-- Name: box_tbl; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.box_tbl (
    f1 box
);


ALTER TABLE public.box_tbl OWNER TO ashutoshpg;

--
-- Name: brin_summarize; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.brin_summarize (
    value integer
)
WITH (fillfactor='10', autovacuum_enabled='false');


ALTER TABLE public.brin_summarize OWNER TO ashutoshpg;

--
-- Name: brin_summarize_bloom; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.brin_summarize_bloom (
    value integer
)
WITH (fillfactor='10', autovacuum_enabled='false');


ALTER TABLE public.brin_summarize_bloom OWNER TO ashutoshpg;

--
-- Name: brin_summarize_multi; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.brin_summarize_multi (
    value integer
)
WITH (fillfactor='10', autovacuum_enabled='false');


ALTER TABLE public.brin_summarize_multi OWNER TO ashutoshpg;

--
-- Name: brin_test; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.brin_test (
    a integer,
    b integer
);


ALTER TABLE public.brin_test OWNER TO ashutoshpg;

--
-- Name: brin_test_bloom; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.brin_test_bloom (
    a integer,
    b integer
);


ALTER TABLE public.brin_test_bloom OWNER TO ashutoshpg;

--
-- Name: brin_test_multi; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.brin_test_multi (
    a integer,
    b integer
);


ALTER TABLE public.brin_test_multi OWNER TO ashutoshpg;

--
-- Name: brinopers; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.brinopers (
    colname name,
    typ text,
    op text[],
    value text[],
    matches integer[],
    CONSTRAINT brinopers_check CHECK ((cardinality(op) = cardinality(value))),
    CONSTRAINT brinopers_check1 CHECK ((cardinality(op) = cardinality(matches)))
);


ALTER TABLE public.brinopers OWNER TO ashutoshpg;

--
-- Name: brinopers_bloom; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.brinopers_bloom (
    colname name,
    typ text,
    op text[],
    value text[],
    matches integer[],
    CONSTRAINT brinopers_bloom_check CHECK ((cardinality(op) = cardinality(value))),
    CONSTRAINT brinopers_bloom_check1 CHECK ((cardinality(op) = cardinality(matches)))
);


ALTER TABLE public.brinopers_bloom OWNER TO ashutoshpg;

--
-- Name: brinopers_multi; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.brinopers_multi (
    colname name,
    typ text,
    op text[],
    value text[],
    matches integer[],
    CONSTRAINT brinopers_multi_check CHECK ((cardinality(op) = cardinality(value))),
    CONSTRAINT brinopers_multi_check1 CHECK ((cardinality(op) = cardinality(matches)))
);


ALTER TABLE public.brinopers_multi OWNER TO ashutoshpg;

--
-- Name: brintest; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.brintest (
    byteacol bytea,
    charcol "char",
    namecol name,
    int8col bigint,
    int2col smallint,
    int4col integer,
    textcol text,
    oidcol oid,
    tidcol tid,
    float4col real,
    float8col double precision,
    macaddrcol macaddr,
    inetcol inet,
    cidrcol cidr,
    bpcharcol character(1),
    datecol date,
    timecol time without time zone,
    timestampcol timestamp without time zone,
    timestamptzcol timestamp with time zone,
    intervalcol interval,
    timetzcol time with time zone,
    bitcol bit(10),
    varbitcol bit varying(16),
    numericcol numeric,
    uuidcol uuid,
    int4rangecol int4range,
    lsncol pg_lsn,
    boxcol box
)
WITH (fillfactor='10', autovacuum_enabled=off);


ALTER TABLE public.brintest OWNER TO ashutoshpg;

--
-- Name: brintest_bloom; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.brintest_bloom (
    byteacol bytea,
    charcol "char",
    namecol name,
    int8col bigint,
    int2col smallint,
    int4col integer,
    textcol text,
    oidcol oid,
    float4col real,
    float8col double precision,
    macaddrcol macaddr,
    inetcol inet,
    cidrcol cidr,
    bpcharcol character(1),
    datecol date,
    timecol time without time zone,
    timestampcol timestamp without time zone,
    timestamptzcol timestamp with time zone,
    intervalcol interval,
    timetzcol time with time zone,
    numericcol numeric,
    uuidcol uuid,
    lsncol pg_lsn
)
WITH (fillfactor='10');


ALTER TABLE public.brintest_bloom OWNER TO ashutoshpg;

--
-- Name: brintest_multi; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.brintest_multi (
    int8col bigint,
    int2col smallint,
    int4col integer,
    oidcol oid,
    tidcol tid,
    float4col real,
    float8col double precision,
    macaddrcol macaddr,
    macaddr8col macaddr8,
    inetcol inet,
    cidrcol cidr,
    datecol date,
    timecol time without time zone,
    timestampcol timestamp without time zone,
    timestamptzcol timestamp with time zone,
    intervalcol interval,
    timetzcol time with time zone,
    numericcol numeric,
    uuidcol uuid,
    lsncol pg_lsn
)
WITH (fillfactor='10');


ALTER TABLE public.brintest_multi OWNER TO ashutoshpg;

--
-- Name: bt_f8_heap; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.bt_f8_heap (
    seqno double precision,
    random integer
);


ALTER TABLE public.bt_f8_heap OWNER TO ashutoshpg;

--
-- Name: bt_i4_heap; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.bt_i4_heap (
    seqno integer,
    random integer
);


ALTER TABLE public.bt_i4_heap OWNER TO ashutoshpg;

--
-- Name: bt_name_heap; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.bt_name_heap (
    seqno name,
    random integer
);


ALTER TABLE public.bt_name_heap OWNER TO ashutoshpg;

--
-- Name: bt_txt_heap; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.bt_txt_heap (
    seqno text,
    random integer
);


ALTER TABLE public.bt_txt_heap OWNER TO ashutoshpg;

--
-- Name: btree_tall_tbl; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.btree_tall_tbl (
    id integer,
    t text
);
ALTER TABLE ONLY public.btree_tall_tbl ALTER COLUMN t SET STORAGE PLAIN;


ALTER TABLE public.btree_tall_tbl OWNER TO ashutoshpg;

--
-- Name: bug_16784; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.bug_16784 (
    i integer,
    j integer
)
WITH (autovacuum_enabled='false');


ALTER TABLE public.bug_16784 OWNER TO ashutoshpg;

--
-- Name: c; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.c (
    cc text
)
INHERITS (public.a);


ALTER TABLE public.c OWNER TO ashutoshpg;

--
-- Name: c_star; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.c_star (
    cc name
)
INHERITS (public.a_star);


ALTER TABLE public.c_star OWNER TO ashutoshpg;

--
-- Name: pp1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.pp1 (
    f1 integer NOT NULL
);


ALTER TABLE public.pp1 OWNER TO ashutoshpg;

--
-- Name: cc1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.cc1 (
    f2 text,
    f3 integer,
    a2 integer
)
INHERITS (public.pp1);


ALTER TABLE public.cc1 OWNER TO ashutoshpg;

--
-- Name: cc2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.cc2 (
    f4 double precision
)
INHERITS (public.pp1, public.cc1);


ALTER TABLE public.cc2 OWNER TO ashutoshpg;

--
-- Name: char_tbl; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.char_tbl (
    f1 character(4)
);


ALTER TABLE public.char_tbl OWNER TO ashutoshpg;

--
-- Name: check2_tbl; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.check2_tbl (
    x integer,
    y text,
    z integer,
    CONSTRAINT sequence_con CHECK (((x > 3) AND (y <> 'check failed'::text) AND (z < 8)))
);


ALTER TABLE public.check2_tbl OWNER TO ashutoshpg;

--
-- Name: check_seq; Type: SEQUENCE; Schema: public; Owner: ashutoshpg
--

CREATE SEQUENCE public.check_seq
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1;


ALTER SEQUENCE public.check_seq OWNER TO ashutoshpg;

--
-- Name: check_tbl; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.check_tbl (
    x integer,
    CONSTRAINT check_con CHECK ((x > 3))
);


ALTER TABLE public.check_tbl OWNER TO ashutoshpg;

--
-- Name: circle_tbl; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.circle_tbl (
    f1 circle
);


ALTER TABLE public.circle_tbl OWNER TO ashutoshpg;

--
-- Name: city; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.city (
    name name,
    location box,
    budget public.city_budget
);


ALTER TABLE public.city OWNER TO ashutoshpg;

--
-- Name: classv; Type: VIEW; Schema: public; Owner: ashutoshpg
--

CREATE VIEW public.classv AS
 SELECT oid,
    relname,
    relnamespace,
    reltype,
    reloftype,
    relowner,
    relam,
    relfilenode,
    reltablespace,
    relpages,
    reltuples,
    relallvisible,
    reltoastrelid,
    relhasindex,
    relisshared,
    relpersistence,
    relkind,
    relnatts,
    relchecks,
    relhasrules,
    relhastriggers,
    relhassubclass,
    relrowsecurity,
    relforcerowsecurity,
    relispopulated,
    relreplident,
    relispartition,
    relrewrite,
    relfrozenxid,
    relminmxid,
    relacl,
    reloptions,
    relpartbound
   FROM pg_class;


ALTER VIEW public.classv OWNER TO ashutoshpg;

--
-- Name: clstr_tst; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.clstr_tst (
    a integer NOT NULL,
    b integer,
    c text,
    d text
);


ALTER TABLE public.clstr_tst OWNER TO ashutoshpg;

--
-- Name: clstr_tst_a_seq; Type: SEQUENCE; Schema: public; Owner: ashutoshpg
--

CREATE SEQUENCE public.clstr_tst_a_seq
    AS integer
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1;


ALTER SEQUENCE public.clstr_tst_a_seq OWNER TO ashutoshpg;

--
-- Name: clstr_tst_a_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: ashutoshpg
--

ALTER SEQUENCE public.clstr_tst_a_seq OWNED BY public.clstr_tst.a;


--
-- Name: clstr_tst_inh; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.clstr_tst_inh (
)
INHERITS (public.clstr_tst);


ALTER TABLE public.clstr_tst_inh OWNER TO ashutoshpg;

--
-- Name: clstr_tst_s; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.clstr_tst_s (
    rf_a integer NOT NULL,
    b integer
);


ALTER TABLE public.clstr_tst_s OWNER TO ashutoshpg;

--
-- Name: clstr_tst_s_rf_a_seq; Type: SEQUENCE; Schema: public; Owner: ashutoshpg
--

CREATE SEQUENCE public.clstr_tst_s_rf_a_seq
    AS integer
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1;


ALTER SEQUENCE public.clstr_tst_s_rf_a_seq OWNER TO ashutoshpg;

--
-- Name: clstr_tst_s_rf_a_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: ashutoshpg
--

ALTER SEQUENCE public.clstr_tst_s_rf_a_seq OWNED BY public.clstr_tst_s.rf_a;


--
-- Name: cmdata; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.cmdata (
    f1 text
);
ALTER TABLE ONLY public.cmdata ALTER COLUMN f1 SET COMPRESSION lz4;


ALTER TABLE public.cmdata OWNER TO ashutoshpg;

--
-- Name: cmdata1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.cmdata1 (
    f1 text
);
ALTER TABLE ONLY public.cmdata1 ALTER COLUMN f1 SET COMPRESSION lz4;


ALTER TABLE public.cmdata1 OWNER TO ashutoshpg;

--
-- Name: cmdata2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.cmdata2 (
    f1 text,
    f2 text
);
ALTER TABLE ONLY public.cmdata2 ALTER COLUMN f1 SET COMPRESSION pglz;
ALTER TABLE ONLY public.cmdata2 ALTER COLUMN f2 SET COMPRESSION lz4;


ALTER TABLE public.cmdata2 OWNER TO ashutoshpg;

--
-- Name: cmdata3; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.cmdata3 (
    f1 text
);


ALTER TABLE public.cmdata3 OWNER TO ashutoshpg;

--
-- Name: cminh; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.cminh (
)
INHERITS (public.cmdata, public.cmdata3);
ALTER TABLE ONLY public.cminh ALTER COLUMN f1 SET COMPRESSION pglz;


ALTER TABLE public.cminh OWNER TO ashutoshpg;

--
-- Name: cmmove1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.cmmove1 (
    f1 text
);


ALTER TABLE public.cmmove1 OWNER TO ashutoshpg;

--
-- Name: cmmove2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.cmmove2 (
    f1 text
);
ALTER TABLE ONLY public.cmmove2 ALTER COLUMN f1 SET COMPRESSION pglz;


ALTER TABLE public.cmmove2 OWNER TO ashutoshpg;

--
-- Name: cmmove3; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.cmmove3 (
    f1 text
);
ALTER TABLE ONLY public.cmmove3 ALTER COLUMN f1 SET COMPRESSION pglz;


ALTER TABLE public.cmmove3 OWNER TO ashutoshpg;

--
-- Name: cmpart; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.cmpart (
    f1 text
)
PARTITION BY HASH (f1);
ALTER TABLE ONLY public.cmpart ALTER COLUMN f1 SET COMPRESSION lz4;


ALTER TABLE public.cmpart OWNER TO ashutoshpg;

--
-- Name: cmpart1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.cmpart1 (
    f1 text
);
ALTER TABLE ONLY public.cmpart1 ALTER COLUMN f1 SET COMPRESSION pglz;


ALTER TABLE public.cmpart1 OWNER TO ashutoshpg;

--
-- Name: cmpart2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.cmpart2 (
    f1 text
);
ALTER TABLE ONLY public.cmpart2 ALTER COLUMN f1 SET COMPRESSION lz4;


ALTER TABLE public.cmpart2 OWNER TO ashutoshpg;

--
-- Name: cnn_uq; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.cnn_uq (
    a integer
);


ALTER TABLE public.cnn_uq OWNER TO ashutoshpg;

--
-- Name: comment_test; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.comment_test (
    id text CONSTRAINT id_notnull_constraint NOT NULL,
    positive_col bigint,
    indexed_col text,
    CONSTRAINT comment_test_positive_col_check CHECK ((positive_col > 0))
);


ALTER TABLE public.comment_test OWNER TO ashutoshpg;

--
-- Name: COLUMN comment_test.id; Type: COMMENT; Schema: public; Owner: ashutoshpg
--

COMMENT ON COLUMN public.comment_test.id IS 'Column ''id'' on comment_test';


--
-- Name: CONSTRAINT comment_test_positive_col_check ON comment_test; Type: COMMENT; Schema: public; Owner: ashutoshpg
--

COMMENT ON CONSTRAINT comment_test_positive_col_check ON public.comment_test IS 'CHECK constraint on comment_test.positive_col';


--
-- Name: comment_test_child; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.comment_test_child (
    id text
);


ALTER TABLE public.comment_test_child OWNER TO ashutoshpg;

--
-- Name: COLUMN comment_test_child.id; Type: COMMENT; Schema: public; Owner: ashutoshpg
--

COMMENT ON COLUMN public.comment_test_child.id IS 'Column ''id'' on comment_test_child';


--
-- Name: compressmv; Type: MATERIALIZED VIEW; Schema: public; Owner: ashutoshpg
--

CREATE MATERIALIZED VIEW public.compressmv AS
 SELECT f1 AS x
   FROM public.cmdata1
  WITH NO DATA;
ALTER TABLE ONLY public.compressmv ALTER COLUMN x SET COMPRESSION lz4;


ALTER MATERIALIZED VIEW public.compressmv OWNER TO ashutoshpg;

--
-- Name: copy_tbl; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.copy_tbl (
    x integer,
    y text,
    z integer,
    CONSTRAINT copy_con CHECK (((x > 3) AND (y <> 'check failed'::text) AND (x < 7)))
);


ALTER TABLE public.copy_tbl OWNER TO ashutoshpg;

--
-- Name: covidxpart; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.covidxpart (
    a integer,
    b integer
)
PARTITION BY LIST (a);


ALTER TABLE public.covidxpart OWNER TO ashutoshpg;

--
-- Name: covidxpart1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.covidxpart1 (
    a integer,
    b integer
);


ALTER TABLE public.covidxpart1 OWNER TO ashutoshpg;

--
-- Name: covidxpart2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.covidxpart2 (
    a integer,
    b integer
);


ALTER TABLE public.covidxpart2 OWNER TO ashutoshpg;

--
-- Name: covidxpart3; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.covidxpart3 (
    b integer,
    a integer
);


ALTER TABLE public.covidxpart3 OWNER TO ashutoshpg;

--
-- Name: covidxpart4; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.covidxpart4 (
    b integer,
    a integer
);


ALTER TABLE public.covidxpart4 OWNER TO ashutoshpg;

--
-- Name: credit_card; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.credit_card (
    cid integer,
    cnum text,
    climit integer
);


ALTER TABLE public.credit_card OWNER TO ashutoshpg;

--
-- Name: credit_usage; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.credit_usage (
    cid integer,
    ymd date,
    usage integer
);


ALTER TABLE public.credit_usage OWNER TO ashutoshpg;

--
-- Name: customer; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.customer (
    cid integer NOT NULL,
    name text NOT NULL,
    tel text,
    passwd text
);


ALTER TABLE public.customer OWNER TO ashutoshpg;

--
-- Name: d; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.d (
    dd text
)
INHERITS (public.b, public.c, public.a);


ALTER TABLE public.d OWNER TO ashutoshpg;

--
-- Name: d_star; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.d_star (
    dd double precision
)
INHERITS (public.b_star, public.c_star);


ALTER TABLE public.d_star OWNER TO ashutoshpg;

--
-- Name: datdba_only; Type: TABLE; Schema: public; Owner: pg_database_owner
--

CREATE TABLE public.datdba_only (
);


ALTER TABLE public.datdba_only OWNER TO pg_database_owner;

--
-- Name: date_tbl; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.date_tbl (
    f1 date
);


ALTER TABLE public.date_tbl OWNER TO ashutoshpg;

--
-- Name: dedup_unique_test_table; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.dedup_unique_test_table (
    a integer
)
WITH (autovacuum_enabled='false');


ALTER TABLE public.dedup_unique_test_table OWNER TO ashutoshpg;

--
-- Name: default_seq; Type: SEQUENCE; Schema: public; Owner: ashutoshpg
--

CREATE SEQUENCE public.default_seq
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1;


ALTER SEQUENCE public.default_seq OWNER TO ashutoshpg;

--
-- Name: default_tbl; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.default_tbl (
    i integer DEFAULT 100,
    x text DEFAULT 'vadim'::text,
    f double precision DEFAULT 123.456
);


ALTER TABLE public.default_tbl OWNER TO ashutoshpg;

--
-- Name: defaultexpr_tbl; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.defaultexpr_tbl (
    i1 integer DEFAULT (100 + ((200 - 199) * 2)),
    i2 integer DEFAULT nextval('public.default_seq'::regclass)
);


ALTER TABLE public.defaultexpr_tbl OWNER TO ashutoshpg;

--
-- Name: defpart_attach_test_2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.defpart_attach_test_2 (
    a integer
);


ALTER TABLE public.defpart_attach_test_2 OWNER TO ashutoshpg;

--
-- Name: delete_test_table; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.delete_test_table (
    a bigint NOT NULL,
    b bigint NOT NULL,
    c bigint NOT NULL,
    d bigint NOT NULL
);


ALTER TABLE public.delete_test_table OWNER TO ashutoshpg;

--
-- Name: depth0; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.depth0 (
    c text
);


ALTER TABLE public.depth0 OWNER TO ashutoshpg;

--
-- Name: depth1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.depth1 (
    c text
)
INHERITS (public.depth0);


ALTER TABLE public.depth1 OWNER TO ashutoshpg;

--
-- Name: depth2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.depth2 (
)
INHERITS (public.depth1);


ALTER TABLE public.depth2 OWNER TO ashutoshpg;

--
-- Name: domain_test; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.domain_test (
    a integer,
    b integer
);


ALTER TABLE public.domain_test OWNER TO ashutoshpg;

--
-- Name: domcontest; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.domcontest (
    col1 public.con
);


ALTER TABLE public.domcontest OWNER TO ashutoshpg;

--
-- Name: domnotnull; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.domnotnull (
);


ALTER TABLE public.domnotnull OWNER TO ashutoshpg;

--
-- Name: domtab; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.domtab (
    col1 integer
);


ALTER TABLE public.domtab OWNER TO ashutoshpg;

--
-- Name: domview; Type: VIEW; Schema: public; Owner: ashutoshpg
--

CREATE VIEW public.domview AS
 SELECT (col1)::public.dom AS col1
   FROM public.domtab;


ALTER VIEW public.domview OWNER TO ashutoshpg;

--
-- Name: dropcolumn; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.dropcolumn (
    b integer
);


ALTER TABLE public.dropcolumn OWNER TO ashutoshpg;

--
-- Name: dropcolumnchild; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.dropcolumnchild (
    e integer
)
INHERITS (public.dropcolumn);


ALTER TABLE public.dropcolumnchild OWNER TO ashutoshpg;

--
-- Name: dropcolumnanother; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.dropcolumnanother (
    d integer
)
INHERITS (public.dropcolumnchild);


ALTER TABLE public.dropcolumnanother OWNER TO ashutoshpg;

--
-- Name: dropcolumnexists; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.dropcolumnexists (
);


ALTER TABLE public.dropcolumnexists OWNER TO ashutoshpg;

--
-- Name: dropped_objects; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.dropped_objects (
    type text,
    schema text,
    object text
);


ALTER TABLE public.dropped_objects OWNER TO ashutoshpg;

--
-- Name: dupindexcols; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.dupindexcols (
    id integer,
    f1 text COLLATE pg_catalog."C"
);


ALTER TABLE public.dupindexcols OWNER TO ashutoshpg;

--
-- Name: e_star; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.e_star (
    ee smallint,
    e integer
)
INHERITS (public.c_star);


ALTER TABLE public.e_star OWNER TO ashutoshpg;

--
-- Name: ec0; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.ec0 (
    ff bigint NOT NULL,
    f1 bigint,
    f2 bigint
);


ALTER TABLE public.ec0 OWNER TO ashutoshpg;

--
-- Name: ec1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.ec1 (
    ff bigint NOT NULL,
    f1 public.int8alias1,
    f2 public.int8alias2
);


ALTER TABLE public.ec1 OWNER TO ashutoshpg;

--
-- Name: ec2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.ec2 (
    xf bigint NOT NULL,
    x1 public.int8alias1,
    x2 public.int8alias2
);


ALTER TABLE public.ec2 OWNER TO ashutoshpg;

--
-- Name: euc_jis_2004_inputs; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.euc_jis_2004_inputs (
    inbytes bytea,
    description text
);


ALTER TABLE public.euc_jis_2004_inputs OWNER TO ashutoshpg;

--
-- Name: event_trigger_test; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.event_trigger_test (
    a integer,
    b text
);


ALTER TABLE public.event_trigger_test OWNER TO ashutoshpg;

--
-- Name: extra_wide_table; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.extra_wide_table (
    firstc text,
    c1 boolean,
    c2 boolean,
    c3 boolean,
    c4 boolean,
    c5 boolean,
    c6 boolean,
    c7 boolean,
    c8 boolean,
    c9 boolean,
    c10 boolean,
    c11 boolean,
    c12 boolean,
    c13 boolean,
    c14 boolean,
    c15 boolean,
    c16 boolean,
    c17 boolean,
    c18 boolean,
    c19 boolean,
    c20 boolean,
    c21 boolean,
    c22 boolean,
    c23 boolean,
    c24 boolean,
    c25 boolean,
    c26 boolean,
    c27 boolean,
    c28 boolean,
    c29 boolean,
    c30 boolean,
    c31 boolean,
    c32 boolean,
    c33 boolean,
    c34 boolean,
    c35 boolean,
    c36 boolean,
    c37 boolean,
    c38 boolean,
    c39 boolean,
    c40 boolean,
    c41 boolean,
    c42 boolean,
    c43 boolean,
    c44 boolean,
    c45 boolean,
    c46 boolean,
    c47 boolean,
    c48 boolean,
    c49 boolean,
    c50 boolean,
    c51 boolean,
    c52 boolean,
    c53 boolean,
    c54 boolean,
    c55 boolean,
    c56 boolean,
    c57 boolean,
    c58 boolean,
    c59 boolean,
    c60 boolean,
    c61 boolean,
    c62 boolean,
    c63 boolean,
    c64 boolean,
    c65 boolean,
    c66 boolean,
    c67 boolean,
    c68 boolean,
    c69 boolean,
    c70 boolean,
    c71 boolean,
    c72 boolean,
    c73 boolean,
    c74 boolean,
    c75 boolean,
    c76 boolean,
    c77 boolean,
    c78 boolean,
    c79 boolean,
    c80 boolean,
    c81 boolean,
    c82 boolean,
    c83 boolean,
    c84 boolean,
    c85 boolean,
    c86 boolean,
    c87 boolean,
    c88 boolean,
    c89 boolean,
    c90 boolean,
    c91 boolean,
    c92 boolean,
    c93 boolean,
    c94 boolean,
    c95 boolean,
    c96 boolean,
    c97 boolean,
    c98 boolean,
    c99 boolean,
    c100 boolean,
    c101 boolean,
    c102 boolean,
    c103 boolean,
    c104 boolean,
    c105 boolean,
    c106 boolean,
    c107 boolean,
    c108 boolean,
    c109 boolean,
    c110 boolean,
    c111 boolean,
    c112 boolean,
    c113 boolean,
    c114 boolean,
    c115 boolean,
    c116 boolean,
    c117 boolean,
    c118 boolean,
    c119 boolean,
    c120 boolean,
    c121 boolean,
    c122 boolean,
    c123 boolean,
    c124 boolean,
    c125 boolean,
    c126 boolean,
    c127 boolean,
    c128 boolean,
    c129 boolean,
    c130 boolean,
    c131 boolean,
    c132 boolean,
    c133 boolean,
    c134 boolean,
    c135 boolean,
    c136 boolean,
    c137 boolean,
    c138 boolean,
    c139 boolean,
    c140 boolean,
    c141 boolean,
    c142 boolean,
    c143 boolean,
    c144 boolean,
    c145 boolean,
    c146 boolean,
    c147 boolean,
    c148 boolean,
    c149 boolean,
    c150 boolean,
    c151 boolean,
    c152 boolean,
    c153 boolean,
    c154 boolean,
    c155 boolean,
    c156 boolean,
    c157 boolean,
    c158 boolean,
    c159 boolean,
    c160 boolean,
    c161 boolean,
    c162 boolean,
    c163 boolean,
    c164 boolean,
    c165 boolean,
    c166 boolean,
    c167 boolean,
    c168 boolean,
    c169 boolean,
    c170 boolean,
    c171 boolean,
    c172 boolean,
    c173 boolean,
    c174 boolean,
    c175 boolean,
    c176 boolean,
    c177 boolean,
    c178 boolean,
    c179 boolean,
    c180 boolean,
    c181 boolean,
    c182 boolean,
    c183 boolean,
    c184 boolean,
    c185 boolean,
    c186 boolean,
    c187 boolean,
    c188 boolean,
    c189 boolean,
    c190 boolean,
    c191 boolean,
    c192 boolean,
    c193 boolean,
    c194 boolean,
    c195 boolean,
    c196 boolean,
    c197 boolean,
    c198 boolean,
    c199 boolean,
    c200 boolean,
    c201 boolean,
    c202 boolean,
    c203 boolean,
    c204 boolean,
    c205 boolean,
    c206 boolean,
    c207 boolean,
    c208 boolean,
    c209 boolean,
    c210 boolean,
    c211 boolean,
    c212 boolean,
    c213 boolean,
    c214 boolean,
    c215 boolean,
    c216 boolean,
    c217 boolean,
    c218 boolean,
    c219 boolean,
    c220 boolean,
    c221 boolean,
    c222 boolean,
    c223 boolean,
    c224 boolean,
    c225 boolean,
    c226 boolean,
    c227 boolean,
    c228 boolean,
    c229 boolean,
    c230 boolean,
    c231 boolean,
    c232 boolean,
    c233 boolean,
    c234 boolean,
    c235 boolean,
    c236 boolean,
    c237 boolean,
    c238 boolean,
    c239 boolean,
    c240 boolean,
    c241 boolean,
    c242 boolean,
    c243 boolean,
    c244 boolean,
    c245 boolean,
    c246 boolean,
    c247 boolean,
    c248 boolean,
    c249 boolean,
    c250 boolean,
    c251 boolean,
    c252 boolean,
    c253 boolean,
    c254 boolean,
    c255 boolean,
    c256 boolean,
    c257 boolean,
    c258 boolean,
    c259 boolean,
    c260 boolean,
    c261 boolean,
    c262 boolean,
    c263 boolean,
    c264 boolean,
    c265 boolean,
    c266 boolean,
    c267 boolean,
    c268 boolean,
    c269 boolean,
    c270 boolean,
    c271 boolean,
    c272 boolean,
    c273 boolean,
    c274 boolean,
    c275 boolean,
    c276 boolean,
    c277 boolean,
    c278 boolean,
    c279 boolean,
    c280 boolean,
    c281 boolean,
    c282 boolean,
    c283 boolean,
    c284 boolean,
    c285 boolean,
    c286 boolean,
    c287 boolean,
    c288 boolean,
    c289 boolean,
    c290 boolean,
    c291 boolean,
    c292 boolean,
    c293 boolean,
    c294 boolean,
    c295 boolean,
    c296 boolean,
    c297 boolean,
    c298 boolean,
    c299 boolean,
    c300 boolean,
    c301 boolean,
    c302 boolean,
    c303 boolean,
    c304 boolean,
    c305 boolean,
    c306 boolean,
    c307 boolean,
    c308 boolean,
    c309 boolean,
    c310 boolean,
    c311 boolean,
    c312 boolean,
    c313 boolean,
    c314 boolean,
    c315 boolean,
    c316 boolean,
    c317 boolean,
    c318 boolean,
    c319 boolean,
    c320 boolean,
    c321 boolean,
    c322 boolean,
    c323 boolean,
    c324 boolean,
    c325 boolean,
    c326 boolean,
    c327 boolean,
    c328 boolean,
    c329 boolean,
    c330 boolean,
    c331 boolean,
    c332 boolean,
    c333 boolean,
    c334 boolean,
    c335 boolean,
    c336 boolean,
    c337 boolean,
    c338 boolean,
    c339 boolean,
    c340 boolean,
    c341 boolean,
    c342 boolean,
    c343 boolean,
    c344 boolean,
    c345 boolean,
    c346 boolean,
    c347 boolean,
    c348 boolean,
    c349 boolean,
    c350 boolean,
    c351 boolean,
    c352 boolean,
    c353 boolean,
    c354 boolean,
    c355 boolean,
    c356 boolean,
    c357 boolean,
    c358 boolean,
    c359 boolean,
    c360 boolean,
    c361 boolean,
    c362 boolean,
    c363 boolean,
    c364 boolean,
    c365 boolean,
    c366 boolean,
    c367 boolean,
    c368 boolean,
    c369 boolean,
    c370 boolean,
    c371 boolean,
    c372 boolean,
    c373 boolean,
    c374 boolean,
    c375 boolean,
    c376 boolean,
    c377 boolean,
    c378 boolean,
    c379 boolean,
    c380 boolean,
    c381 boolean,
    c382 boolean,
    c383 boolean,
    c384 boolean,
    c385 boolean,
    c386 boolean,
    c387 boolean,
    c388 boolean,
    c389 boolean,
    c390 boolean,
    c391 boolean,
    c392 boolean,
    c393 boolean,
    c394 boolean,
    c395 boolean,
    c396 boolean,
    c397 boolean,
    c398 boolean,
    c399 boolean,
    c400 boolean,
    c401 boolean,
    c402 boolean,
    c403 boolean,
    c404 boolean,
    c405 boolean,
    c406 boolean,
    c407 boolean,
    c408 boolean,
    c409 boolean,
    c410 boolean,
    c411 boolean,
    c412 boolean,
    c413 boolean,
    c414 boolean,
    c415 boolean,
    c416 boolean,
    c417 boolean,
    c418 boolean,
    c419 boolean,
    c420 boolean,
    c421 boolean,
    c422 boolean,
    c423 boolean,
    c424 boolean,
    c425 boolean,
    c426 boolean,
    c427 boolean,
    c428 boolean,
    c429 boolean,
    c430 boolean,
    c431 boolean,
    c432 boolean,
    c433 boolean,
    c434 boolean,
    c435 boolean,
    c436 boolean,
    c437 boolean,
    c438 boolean,
    c439 boolean,
    c440 boolean,
    c441 boolean,
    c442 boolean,
    c443 boolean,
    c444 boolean,
    c445 boolean,
    c446 boolean,
    c447 boolean,
    c448 boolean,
    c449 boolean,
    c450 boolean,
    c451 boolean,
    c452 boolean,
    c453 boolean,
    c454 boolean,
    c455 boolean,
    c456 boolean,
    c457 boolean,
    c458 boolean,
    c459 boolean,
    c460 boolean,
    c461 boolean,
    c462 boolean,
    c463 boolean,
    c464 boolean,
    c465 boolean,
    c466 boolean,
    c467 boolean,
    c468 boolean,
    c469 boolean,
    c470 boolean,
    c471 boolean,
    c472 boolean,
    c473 boolean,
    c474 boolean,
    c475 boolean,
    c476 boolean,
    c477 boolean,
    c478 boolean,
    c479 boolean,
    c480 boolean,
    c481 boolean,
    c482 boolean,
    c483 boolean,
    c484 boolean,
    c485 boolean,
    c486 boolean,
    c487 boolean,
    c488 boolean,
    c489 boolean,
    c490 boolean,
    c491 boolean,
    c492 boolean,
    c493 boolean,
    c494 boolean,
    c495 boolean,
    c496 boolean,
    c497 boolean,
    c498 boolean,
    c499 boolean,
    c500 boolean,
    c501 boolean,
    c502 boolean,
    c503 boolean,
    c504 boolean,
    c505 boolean,
    c506 boolean,
    c507 boolean,
    c508 boolean,
    c509 boolean,
    c510 boolean,
    c511 boolean,
    c512 boolean,
    c513 boolean,
    c514 boolean,
    c515 boolean,
    c516 boolean,
    c517 boolean,
    c518 boolean,
    c519 boolean,
    c520 boolean,
    c521 boolean,
    c522 boolean,
    c523 boolean,
    c524 boolean,
    c525 boolean,
    c526 boolean,
    c527 boolean,
    c528 boolean,
    c529 boolean,
    c530 boolean,
    c531 boolean,
    c532 boolean,
    c533 boolean,
    c534 boolean,
    c535 boolean,
    c536 boolean,
    c537 boolean,
    c538 boolean,
    c539 boolean,
    c540 boolean,
    c541 boolean,
    c542 boolean,
    c543 boolean,
    c544 boolean,
    c545 boolean,
    c546 boolean,
    c547 boolean,
    c548 boolean,
    c549 boolean,
    c550 boolean,
    c551 boolean,
    c552 boolean,
    c553 boolean,
    c554 boolean,
    c555 boolean,
    c556 boolean,
    c557 boolean,
    c558 boolean,
    c559 boolean,
    c560 boolean,
    c561 boolean,
    c562 boolean,
    c563 boolean,
    c564 boolean,
    c565 boolean,
    c566 boolean,
    c567 boolean,
    c568 boolean,
    c569 boolean,
    c570 boolean,
    c571 boolean,
    c572 boolean,
    c573 boolean,
    c574 boolean,
    c575 boolean,
    c576 boolean,
    c577 boolean,
    c578 boolean,
    c579 boolean,
    c580 boolean,
    c581 boolean,
    c582 boolean,
    c583 boolean,
    c584 boolean,
    c585 boolean,
    c586 boolean,
    c587 boolean,
    c588 boolean,
    c589 boolean,
    c590 boolean,
    c591 boolean,
    c592 boolean,
    c593 boolean,
    c594 boolean,
    c595 boolean,
    c596 boolean,
    c597 boolean,
    c598 boolean,
    c599 boolean,
    c600 boolean,
    c601 boolean,
    c602 boolean,
    c603 boolean,
    c604 boolean,
    c605 boolean,
    c606 boolean,
    c607 boolean,
    c608 boolean,
    c609 boolean,
    c610 boolean,
    c611 boolean,
    c612 boolean,
    c613 boolean,
    c614 boolean,
    c615 boolean,
    c616 boolean,
    c617 boolean,
    c618 boolean,
    c619 boolean,
    c620 boolean,
    c621 boolean,
    c622 boolean,
    c623 boolean,
    c624 boolean,
    c625 boolean,
    c626 boolean,
    c627 boolean,
    c628 boolean,
    c629 boolean,
    c630 boolean,
    c631 boolean,
    c632 boolean,
    c633 boolean,
    c634 boolean,
    c635 boolean,
    c636 boolean,
    c637 boolean,
    c638 boolean,
    c639 boolean,
    c640 boolean,
    c641 boolean,
    c642 boolean,
    c643 boolean,
    c644 boolean,
    c645 boolean,
    c646 boolean,
    c647 boolean,
    c648 boolean,
    c649 boolean,
    c650 boolean,
    c651 boolean,
    c652 boolean,
    c653 boolean,
    c654 boolean,
    c655 boolean,
    c656 boolean,
    c657 boolean,
    c658 boolean,
    c659 boolean,
    c660 boolean,
    c661 boolean,
    c662 boolean,
    c663 boolean,
    c664 boolean,
    c665 boolean,
    c666 boolean,
    c667 boolean,
    c668 boolean,
    c669 boolean,
    c670 boolean,
    c671 boolean,
    c672 boolean,
    c673 boolean,
    c674 boolean,
    c675 boolean,
    c676 boolean,
    c677 boolean,
    c678 boolean,
    c679 boolean,
    c680 boolean,
    c681 boolean,
    c682 boolean,
    c683 boolean,
    c684 boolean,
    c685 boolean,
    c686 boolean,
    c687 boolean,
    c688 boolean,
    c689 boolean,
    c690 boolean,
    c691 boolean,
    c692 boolean,
    c693 boolean,
    c694 boolean,
    c695 boolean,
    c696 boolean,
    c697 boolean,
    c698 boolean,
    c699 boolean,
    c700 boolean,
    c701 boolean,
    c702 boolean,
    c703 boolean,
    c704 boolean,
    c705 boolean,
    c706 boolean,
    c707 boolean,
    c708 boolean,
    c709 boolean,
    c710 boolean,
    c711 boolean,
    c712 boolean,
    c713 boolean,
    c714 boolean,
    c715 boolean,
    c716 boolean,
    c717 boolean,
    c718 boolean,
    c719 boolean,
    c720 boolean,
    c721 boolean,
    c722 boolean,
    c723 boolean,
    c724 boolean,
    c725 boolean,
    c726 boolean,
    c727 boolean,
    c728 boolean,
    c729 boolean,
    c730 boolean,
    c731 boolean,
    c732 boolean,
    c733 boolean,
    c734 boolean,
    c735 boolean,
    c736 boolean,
    c737 boolean,
    c738 boolean,
    c739 boolean,
    c740 boolean,
    c741 boolean,
    c742 boolean,
    c743 boolean,
    c744 boolean,
    c745 boolean,
    c746 boolean,
    c747 boolean,
    c748 boolean,
    c749 boolean,
    c750 boolean,
    c751 boolean,
    c752 boolean,
    c753 boolean,
    c754 boolean,
    c755 boolean,
    c756 boolean,
    c757 boolean,
    c758 boolean,
    c759 boolean,
    c760 boolean,
    c761 boolean,
    c762 boolean,
    c763 boolean,
    c764 boolean,
    c765 boolean,
    c766 boolean,
    c767 boolean,
    c768 boolean,
    c769 boolean,
    c770 boolean,
    c771 boolean,
    c772 boolean,
    c773 boolean,
    c774 boolean,
    c775 boolean,
    c776 boolean,
    c777 boolean,
    c778 boolean,
    c779 boolean,
    c780 boolean,
    c781 boolean,
    c782 boolean,
    c783 boolean,
    c784 boolean,
    c785 boolean,
    c786 boolean,
    c787 boolean,
    c788 boolean,
    c789 boolean,
    c790 boolean,
    c791 boolean,
    c792 boolean,
    c793 boolean,
    c794 boolean,
    c795 boolean,
    c796 boolean,
    c797 boolean,
    c798 boolean,
    c799 boolean,
    c800 boolean,
    c801 boolean,
    c802 boolean,
    c803 boolean,
    c804 boolean,
    c805 boolean,
    c806 boolean,
    c807 boolean,
    c808 boolean,
    c809 boolean,
    c810 boolean,
    c811 boolean,
    c812 boolean,
    c813 boolean,
    c814 boolean,
    c815 boolean,
    c816 boolean,
    c817 boolean,
    c818 boolean,
    c819 boolean,
    c820 boolean,
    c821 boolean,
    c822 boolean,
    c823 boolean,
    c824 boolean,
    c825 boolean,
    c826 boolean,
    c827 boolean,
    c828 boolean,
    c829 boolean,
    c830 boolean,
    c831 boolean,
    c832 boolean,
    c833 boolean,
    c834 boolean,
    c835 boolean,
    c836 boolean,
    c837 boolean,
    c838 boolean,
    c839 boolean,
    c840 boolean,
    c841 boolean,
    c842 boolean,
    c843 boolean,
    c844 boolean,
    c845 boolean,
    c846 boolean,
    c847 boolean,
    c848 boolean,
    c849 boolean,
    c850 boolean,
    c851 boolean,
    c852 boolean,
    c853 boolean,
    c854 boolean,
    c855 boolean,
    c856 boolean,
    c857 boolean,
    c858 boolean,
    c859 boolean,
    c860 boolean,
    c861 boolean,
    c862 boolean,
    c863 boolean,
    c864 boolean,
    c865 boolean,
    c866 boolean,
    c867 boolean,
    c868 boolean,
    c869 boolean,
    c870 boolean,
    c871 boolean,
    c872 boolean,
    c873 boolean,
    c874 boolean,
    c875 boolean,
    c876 boolean,
    c877 boolean,
    c878 boolean,
    c879 boolean,
    c880 boolean,
    c881 boolean,
    c882 boolean,
    c883 boolean,
    c884 boolean,
    c885 boolean,
    c886 boolean,
    c887 boolean,
    c888 boolean,
    c889 boolean,
    c890 boolean,
    c891 boolean,
    c892 boolean,
    c893 boolean,
    c894 boolean,
    c895 boolean,
    c896 boolean,
    c897 boolean,
    c898 boolean,
    c899 boolean,
    c900 boolean,
    c901 boolean,
    c902 boolean,
    c903 boolean,
    c904 boolean,
    c905 boolean,
    c906 boolean,
    c907 boolean,
    c908 boolean,
    c909 boolean,
    c910 boolean,
    c911 boolean,
    c912 boolean,
    c913 boolean,
    c914 boolean,
    c915 boolean,
    c916 boolean,
    c917 boolean,
    c918 boolean,
    c919 boolean,
    c920 boolean,
    c921 boolean,
    c922 boolean,
    c923 boolean,
    c924 boolean,
    c925 boolean,
    c926 boolean,
    c927 boolean,
    c928 boolean,
    c929 boolean,
    c930 boolean,
    c931 boolean,
    c932 boolean,
    c933 boolean,
    c934 boolean,
    c935 boolean,
    c936 boolean,
    c937 boolean,
    c938 boolean,
    c939 boolean,
    c940 boolean,
    c941 boolean,
    c942 boolean,
    c943 boolean,
    c944 boolean,
    c945 boolean,
    c946 boolean,
    c947 boolean,
    c948 boolean,
    c949 boolean,
    c950 boolean,
    c951 boolean,
    c952 boolean,
    c953 boolean,
    c954 boolean,
    c955 boolean,
    c956 boolean,
    c957 boolean,
    c958 boolean,
    c959 boolean,
    c960 boolean,
    c961 boolean,
    c962 boolean,
    c963 boolean,
    c964 boolean,
    c965 boolean,
    c966 boolean,
    c967 boolean,
    c968 boolean,
    c969 boolean,
    c970 boolean,
    c971 boolean,
    c972 boolean,
    c973 boolean,
    c974 boolean,
    c975 boolean,
    c976 boolean,
    c977 boolean,
    c978 boolean,
    c979 boolean,
    c980 boolean,
    c981 boolean,
    c982 boolean,
    c983 boolean,
    c984 boolean,
    c985 boolean,
    c986 boolean,
    c987 boolean,
    c988 boolean,
    c989 boolean,
    c990 boolean,
    c991 boolean,
    c992 boolean,
    c993 boolean,
    c994 boolean,
    c995 boolean,
    c996 boolean,
    c997 boolean,
    c998 boolean,
    c999 boolean,
    c1000 boolean,
    c1001 boolean,
    c1002 boolean,
    c1003 boolean,
    c1004 boolean,
    c1005 boolean,
    c1006 boolean,
    c1007 boolean,
    c1008 boolean,
    c1009 boolean,
    c1010 boolean,
    c1011 boolean,
    c1012 boolean,
    c1013 boolean,
    c1014 boolean,
    c1015 boolean,
    c1016 boolean,
    c1017 boolean,
    c1018 boolean,
    c1019 boolean,
    c1020 boolean,
    c1021 boolean,
    c1022 boolean,
    c1023 boolean,
    c1024 boolean,
    c1025 boolean,
    c1026 boolean,
    c1027 boolean,
    c1028 boolean,
    c1029 boolean,
    c1030 boolean,
    c1031 boolean,
    c1032 boolean,
    c1033 boolean,
    c1034 boolean,
    c1035 boolean,
    c1036 boolean,
    c1037 boolean,
    c1038 boolean,
    c1039 boolean,
    c1040 boolean,
    c1041 boolean,
    c1042 boolean,
    c1043 boolean,
    c1044 boolean,
    c1045 boolean,
    c1046 boolean,
    c1047 boolean,
    c1048 boolean,
    c1049 boolean,
    c1050 boolean,
    c1051 boolean,
    c1052 boolean,
    c1053 boolean,
    c1054 boolean,
    c1055 boolean,
    c1056 boolean,
    c1057 boolean,
    c1058 boolean,
    c1059 boolean,
    c1060 boolean,
    c1061 boolean,
    c1062 boolean,
    c1063 boolean,
    c1064 boolean,
    c1065 boolean,
    c1066 boolean,
    c1067 boolean,
    c1068 boolean,
    c1069 boolean,
    c1070 boolean,
    c1071 boolean,
    c1072 boolean,
    c1073 boolean,
    c1074 boolean,
    c1075 boolean,
    c1076 boolean,
    c1077 boolean,
    c1078 boolean,
    c1079 boolean,
    c1080 boolean,
    c1081 boolean,
    c1082 boolean,
    c1083 boolean,
    c1084 boolean,
    c1085 boolean,
    c1086 boolean,
    c1087 boolean,
    c1088 boolean,
    c1089 boolean,
    c1090 boolean,
    c1091 boolean,
    c1092 boolean,
    c1093 boolean,
    c1094 boolean,
    c1095 boolean,
    c1096 boolean,
    c1097 boolean,
    c1098 boolean,
    c1099 boolean,
    c1100 boolean,
    lastc text
);


ALTER TABLE public.extra_wide_table OWNER TO ashutoshpg;

--
-- Name: f_star; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.f_star (
    ff polygon,
    f integer
)
INHERITS (public.e_star);


ALTER TABLE public.f_star OWNER TO ashutoshpg;

--
-- Name: fast_emp4000; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.fast_emp4000 (
    home_base box
);


ALTER TABLE public.fast_emp4000 OWNER TO ashutoshpg;

--
-- Name: fk_notpartitioned_pk; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.fk_notpartitioned_pk (
    a integer NOT NULL,
    b integer NOT NULL
);


ALTER TABLE public.fk_notpartitioned_pk OWNER TO ashutoshpg;

--
-- Name: fk_partitioned_fk; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.fk_partitioned_fk (
    a integer DEFAULT 2501,
    b integer DEFAULT 142857
)
PARTITION BY LIST (a);


ALTER TABLE public.fk_partitioned_fk OWNER TO ashutoshpg;

--
-- Name: fk_partitioned_fk_1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.fk_partitioned_fk_1 (
    a integer DEFAULT 2501,
    b integer DEFAULT 142857
);


ALTER TABLE public.fk_partitioned_fk_1 OWNER TO ashutoshpg;

--
-- Name: fk_partitioned_fk_2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.fk_partitioned_fk_2 (
    a integer DEFAULT NULL,
    b integer DEFAULT NULL
)
PARTITION BY RANGE (b);


ALTER TABLE public.fk_partitioned_fk_2 OWNER TO ashutoshpg;

--
-- Name: fk_partitioned_fk_2_1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.fk_partitioned_fk_2_1 (
    a integer,
    b integer
);


ALTER TABLE public.fk_partitioned_fk_2_1 OWNER TO ashutoshpg;

--
-- Name: fk_partitioned_fk_2_2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.fk_partitioned_fk_2_2 (
    a integer,
    b integer
);


ALTER TABLE public.fk_partitioned_fk_2_2 OWNER TO ashutoshpg;

--
-- Name: fk_partitioned_fk_3; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.fk_partitioned_fk_3 (
    a integer DEFAULT NULL,
    b integer DEFAULT NULL
);


ALTER TABLE public.fk_partitioned_fk_3 OWNER TO ashutoshpg;

--
-- Name: fk_partitioned_fk_4; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.fk_partitioned_fk_4 (
    a integer DEFAULT NULL,
    b integer DEFAULT NULL
)
PARTITION BY RANGE (b, a);


ALTER TABLE public.fk_partitioned_fk_4 OWNER TO ashutoshpg;

--
-- Name: fk_partitioned_fk_4_1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.fk_partitioned_fk_4_1 (
    a integer,
    b integer
);


ALTER TABLE public.fk_partitioned_fk_4_1 OWNER TO ashutoshpg;

--
-- Name: fk_partitioned_fk_4_2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.fk_partitioned_fk_4_2 (
    a integer,
    b integer
);


ALTER TABLE public.fk_partitioned_fk_4_2 OWNER TO ashutoshpg;

--
-- Name: fk_partitioned_fk_5; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.fk_partitioned_fk_5 (
    a integer DEFAULT NULL,
    b integer DEFAULT NULL
)
PARTITION BY RANGE (a);


ALTER TABLE public.fk_partitioned_fk_5 OWNER TO ashutoshpg;

--
-- Name: fk_partitioned_fk_5_1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.fk_partitioned_fk_5_1 (
    a integer,
    b integer
);


ALTER TABLE public.fk_partitioned_fk_5_1 OWNER TO ashutoshpg;

--
-- Name: float4_tbl; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.float4_tbl (
    f1 real
);


ALTER TABLE public.float4_tbl OWNER TO ashutoshpg;

--
-- Name: float8_tbl; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.float8_tbl (
    f1 double precision
);


ALTER TABLE public.float8_tbl OWNER TO ashutoshpg;

--
-- Name: func_index_heap; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.func_index_heap (
    f1 text,
    f2 text
);


ALTER TABLE public.func_index_heap OWNER TO ashutoshpg;

--
-- Name: functional_dependencies; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.functional_dependencies (
    filler1 text,
    filler2 numeric,
    a integer,
    b text,
    filler3 date,
    c numeric,
    d text
)
WITH (autovacuum_enabled=off);


ALTER TABLE public.functional_dependencies OWNER TO ashutoshpg;

--
-- Name: gb18030_inputs; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.gb18030_inputs (
    inbytes bytea,
    description text
);


ALTER TABLE public.gb18030_inputs OWNER TO ashutoshpg;

--
-- Name: gin_test_tbl; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.gin_test_tbl (
    i integer[]
)
WITH (autovacuum_enabled=off);


ALTER TABLE public.gin_test_tbl OWNER TO ashutoshpg;

--
-- Name: gist_point_tbl; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.gist_point_tbl (
    id integer,
    p point
);


ALTER TABLE public.gist_point_tbl OWNER TO ashutoshpg;

--
-- Name: gs_data_1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.gs_data_1 (
    g1000 integer,
    g100 integer,
    g10 integer,
    g integer
)
WITH (autovacuum_enabled='false');


ALTER TABLE public.gs_data_1 OWNER TO ashutoshpg;

--
-- Name: has_fast_default; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.has_fast_default (
    f1 integer,
    f2 integer DEFAULT 42
);


ALTER TABLE public.has_fast_default OWNER TO ashutoshpg;

--
-- Name: hash_f8_heap; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.hash_f8_heap (
    seqno integer,
    random double precision
);


ALTER TABLE public.hash_f8_heap OWNER TO ashutoshpg;

--
-- Name: hash_i4_heap; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.hash_i4_heap (
    seqno integer,
    random integer
);


ALTER TABLE public.hash_i4_heap OWNER TO ashutoshpg;

--
-- Name: hash_name_heap; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.hash_name_heap (
    seqno integer,
    random name
);


ALTER TABLE public.hash_name_heap OWNER TO ashutoshpg;

--
-- Name: hash_txt_heap; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.hash_txt_heap (
    seqno integer,
    random text
);


ALTER TABLE public.hash_txt_heap OWNER TO ashutoshpg;

--
-- Name: hslot; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.hslot (
    slotname character(20),
    hubname character(14),
    slotno integer,
    slotlink character(20)
);


ALTER TABLE public.hslot OWNER TO ashutoshpg;

--
-- Name: hub; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.hub (
    name character(14),
    comment text,
    nslots integer
);


ALTER TABLE public.hub OWNER TO ashutoshpg;

--
-- Name: identity_dump_logged; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.identity_dump_logged (
    a integer NOT NULL
);


ALTER TABLE public.identity_dump_logged OWNER TO ashutoshpg;

--
-- Name: identity_dump_logged_a_seq; Type: SEQUENCE; Schema: public; Owner: ashutoshpg
--

ALTER TABLE public.identity_dump_logged ALTER COLUMN a ADD GENERATED ALWAYS AS IDENTITY (
    SEQUENCE NAME public.identity_dump_logged_a_seq
    UNLOGGED
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1
);


--
-- Name: identity_dump_unlogged; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE UNLOGGED TABLE public.identity_dump_unlogged (
    a integer NOT NULL
);


ALTER TABLE public.identity_dump_unlogged OWNER TO ashutoshpg;

--
-- Name: identity_dump_unlogged_a_seq; Type: SEQUENCE; Schema: public; Owner: ashutoshpg
--

ALTER TABLE public.identity_dump_unlogged ALTER COLUMN a ADD GENERATED ALWAYS AS IDENTITY (
    SEQUENCE NAME public.identity_dump_unlogged_a_seq
    LOGGED
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1
);


--
-- Name: idxpart; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.idxpart (
    a integer
)
PARTITION BY RANGE (a);


ALTER TABLE public.idxpart OWNER TO ashutoshpg;

--
-- Name: idxpart1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.idxpart1 (
    a integer
);


ALTER TABLE public.idxpart1 OWNER TO ashutoshpg;

--
-- Name: idxpart2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.idxpart2 (
    a integer
)
PARTITION BY RANGE (a);


ALTER TABLE public.idxpart2 OWNER TO ashutoshpg;

--
-- Name: idxpart21; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.idxpart21 (
    a integer
);


ALTER TABLE public.idxpart21 OWNER TO ashutoshpg;

--
-- Name: idxpart22; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.idxpart22 (
    a integer
);


ALTER TABLE public.idxpart22 OWNER TO ashutoshpg;

--
-- Name: idxpart3; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.idxpart3 (
    a integer
)
PARTITION BY RANGE (a);


ALTER TABLE public.idxpart3 OWNER TO ashutoshpg;

--
-- Name: idxpart31; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.idxpart31 (
    a integer
);


ALTER TABLE public.idxpart31 OWNER TO ashutoshpg;

--
-- Name: idxpart32; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.idxpart32 (
    a integer
);


ALTER TABLE public.idxpart32 OWNER TO ashutoshpg;

--
-- Name: idxpart_another; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.idxpart_another (
    a integer NOT NULL,
    b integer NOT NULL
)
PARTITION BY RANGE (a);


ALTER TABLE public.idxpart_another OWNER TO ashutoshpg;

--
-- Name: idxpart_another_1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.idxpart_another_1 (
    a integer CONSTRAINT idxpart_another_a_not_null NOT NULL,
    b integer CONSTRAINT idxpart_another_b_not_null NOT NULL
);


ALTER TABLE public.idxpart_another_1 OWNER TO ashutoshpg;

--
-- Name: road; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.road (
    name text,
    thepath path
);


ALTER TABLE public.road OWNER TO ashutoshpg;

--
-- Name: ihighway; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.ihighway (
)
INHERITS (public.road);


ALTER TABLE public.ihighway OWNER TO ashutoshpg;

--
-- Name: ramp; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.ramp (
    name text,
    thepath path
);


ALTER TABLE public.ramp OWNER TO ashutoshpg;

--
-- Name: iexit; Type: VIEW; Schema: public; Owner: ashutoshpg
--

CREATE VIEW public.iexit AS
 SELECT ih.name,
    ih.thepath,
    public.interpt_pp(ih.thepath, r.thepath) AS exit
   FROM public.ihighway ih,
    public.ramp r
  WHERE (ih.thepath ?# r.thepath);


ALTER VIEW public.iexit OWNER TO ashutoshpg;

--
-- Name: iface; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.iface (
    slotname character(20),
    sysname text,
    ifname text,
    slotlink character(20)
);


ALTER TABLE public.iface OWNER TO ashutoshpg;

--
-- Name: inet_tbl; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.inet_tbl (
    c cidr,
    i inet
);


ALTER TABLE public.inet_tbl OWNER TO ashutoshpg;

--
-- Name: infinite_interval_tbl; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.infinite_interval_tbl (
    i interval
);


ALTER TABLE public.infinite_interval_tbl OWNER TO ashutoshpg;

--
-- Name: inh_nn1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.inh_nn1 (
    a integer NOT NULL
);


ALTER TABLE public.inh_nn1 OWNER TO ashutoshpg;

--
-- Name: inh_test; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.inh_test (
    a integer,
    b character(1) CONSTRAINT list_parted2_b_not_null NOT NULL
);


ALTER TABLE public.inh_test OWNER TO ashutoshpg;

--
-- Name: inhf; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.inhf (
    xx text DEFAULT 'text'::text
);


ALTER TABLE public.inhf OWNER TO ashutoshpg;

--
-- Name: inhx; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.inhx (
    xx text DEFAULT 'text'::text NOT NULL,
    CONSTRAINT foo CHECK ((xx = 'text'::text))
);


ALTER TABLE public.inhx OWNER TO ashutoshpg;

--
-- Name: insert_seq; Type: SEQUENCE; Schema: public; Owner: ashutoshpg
--

CREATE SEQUENCE public.insert_seq
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1;


ALTER SEQUENCE public.insert_seq OWNER TO ashutoshpg;

--
-- Name: insert_tbl; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.insert_tbl (
    x integer DEFAULT nextval('public.insert_seq'::regclass),
    y text DEFAULT '-NULL-'::text,
    z integer DEFAULT ('-1'::integer * currval('public.insert_seq'::regclass)),
    CONSTRAINT insert_tbl_check CHECK (((x + z) = 0)),
    CONSTRAINT insert_tbl_con CHECK (((x >= 3) AND (y <> 'check failed'::text) AND (x < 8)))
);


ALTER TABLE public.insert_tbl OWNER TO ashutoshpg;

--
-- Name: int2_tbl; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.int2_tbl (
    f1 smallint
);


ALTER TABLE public.int2_tbl OWNER TO ashutoshpg;

--
-- Name: int4_tbl; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.int4_tbl (
    f1 integer
);


ALTER TABLE public.int4_tbl OWNER TO ashutoshpg;

--
-- Name: interval_tbl; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.interval_tbl (
    f1 interval
);


ALTER TABLE public.interval_tbl OWNER TO ashutoshpg;

--
-- Name: invalid_check_con; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.invalid_check_con (
    f1 integer
);


ALTER TABLE public.invalid_check_con OWNER TO ashutoshpg;

--
-- Name: invalid_check_con_child; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.invalid_check_con_child (
    CONSTRAINT inh_check_constraint CHECK ((f1 > 0))
)
INHERITS (public.invalid_check_con);


ALTER TABLE public.invalid_check_con_child OWNER TO ashutoshpg;

--
-- Name: iso8859_5_inputs; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.iso8859_5_inputs (
    inbytes bytea,
    description text
);


ALTER TABLE public.iso8859_5_inputs OWNER TO ashutoshpg;

--
-- Name: itest1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.itest1 (
    a integer NOT NULL,
    b text
);


ALTER TABLE public.itest1 OWNER TO ashutoshpg;

--
-- Name: itest10; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.itest10 (
    a integer NOT NULL,
    b text
);


ALTER TABLE public.itest10 OWNER TO ashutoshpg;

--
-- Name: itest10_a_seq; Type: SEQUENCE; Schema: public; Owner: ashutoshpg
--

ALTER TABLE public.itest10 ALTER COLUMN a ADD GENERATED BY DEFAULT AS IDENTITY (
    SEQUENCE NAME public.itest10_a_seq
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1
);


--
-- Name: itest11; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.itest11 (
    a integer NOT NULL,
    b text
);


ALTER TABLE public.itest11 OWNER TO ashutoshpg;

--
-- Name: itest11_a_seq; Type: SEQUENCE; Schema: public; Owner: ashutoshpg
--

ALTER TABLE public.itest11 ALTER COLUMN a ADD GENERATED ALWAYS AS IDENTITY (
    SEQUENCE NAME public.itest11_a_seq
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1
);


--
-- Name: itest13; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.itest13 (
    a integer,
    b integer NOT NULL,
    c integer NOT NULL
);


ALTER TABLE public.itest13 OWNER TO ashutoshpg;

--
-- Name: itest13_b_seq; Type: SEQUENCE; Schema: public; Owner: ashutoshpg
--

ALTER TABLE public.itest13 ALTER COLUMN b ADD GENERATED BY DEFAULT AS IDENTITY (
    SEQUENCE NAME public.itest13_b_seq
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1
);


--
-- Name: itest13_c_seq; Type: SEQUENCE; Schema: public; Owner: ashutoshpg
--

ALTER TABLE public.itest13 ALTER COLUMN c ADD GENERATED BY DEFAULT AS IDENTITY (
    SEQUENCE NAME public.itest13_c_seq
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1
);


--
-- Name: itest14; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.itest14 (
    id integer NOT NULL
);


ALTER TABLE public.itest14 OWNER TO ashutoshpg;

--
-- Name: itest14_id_seq; Type: SEQUENCE; Schema: public; Owner: ashutoshpg
--

CREATE SEQUENCE public.itest14_id_seq
    AS integer
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1;


ALTER SEQUENCE public.itest14_id_seq OWNER TO ashutoshpg;

--
-- Name: itest14_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: ashutoshpg
--

ALTER SEQUENCE public.itest14_id_seq OWNED BY public.itest14.id;


--
-- Name: itest14_id_seq1; Type: SEQUENCE; Schema: public; Owner: ashutoshpg
--

ALTER TABLE public.itest14 ALTER COLUMN id ADD GENERATED BY DEFAULT AS IDENTITY (
    SEQUENCE NAME public.itest14_id_seq1
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1
);


--
-- Name: itest17; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE UNLOGGED TABLE public.itest17 (
    a integer NOT NULL,
    b text,
    c integer NOT NULL
);


ALTER TABLE public.itest17 OWNER TO ashutoshpg;

--
-- Name: itest17_a_seq; Type: SEQUENCE; Schema: public; Owner: ashutoshpg
--

ALTER TABLE public.itest17 ALTER COLUMN a ADD GENERATED ALWAYS AS IDENTITY (
    SEQUENCE NAME public.itest17_a_seq
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1
);


--
-- Name: itest17_c_seq; Type: SEQUENCE; Schema: public; Owner: ashutoshpg
--

ALTER TABLE public.itest17 ALTER COLUMN c ADD GENERATED ALWAYS AS IDENTITY (
    SEQUENCE NAME public.itest17_c_seq
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1
);


--
-- Name: itest18; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE UNLOGGED TABLE public.itest18 (
    a integer NOT NULL,
    b text
);


ALTER TABLE public.itest18 OWNER TO ashutoshpg;

--
-- Name: itest18_a_seq; Type: SEQUENCE; Schema: public; Owner: ashutoshpg
--

ALTER TABLE public.itest18 ALTER COLUMN a ADD GENERATED ALWAYS AS IDENTITY (
    SEQUENCE NAME public.itest18_a_seq
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1
);


--
-- Name: itest1_a_seq; Type: SEQUENCE; Schema: public; Owner: ashutoshpg
--

ALTER TABLE public.itest1 ALTER COLUMN a ADD GENERATED BY DEFAULT AS IDENTITY (
    SEQUENCE NAME public.itest1_a_seq
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1
);


--
-- Name: itest2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.itest2 (
    a bigint NOT NULL,
    b text
);


ALTER TABLE public.itest2 OWNER TO ashutoshpg;

--
-- Name: itest2_a_seq; Type: SEQUENCE; Schema: public; Owner: ashutoshpg
--

ALTER TABLE public.itest2 ALTER COLUMN a ADD GENERATED ALWAYS AS IDENTITY (
    SEQUENCE NAME public.itest2_a_seq
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1
);


--
-- Name: itest3; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.itest3 (
    a integer NOT NULL,
    b text,
    c integer NOT NULL
);


ALTER TABLE public.itest3 OWNER TO ashutoshpg;

--
-- Name: itest3_a_seq; Type: SEQUENCE; Schema: public; Owner: ashutoshpg
--

ALTER TABLE public.itest3 ALTER COLUMN a ADD GENERATED BY DEFAULT AS IDENTITY (
    SEQUENCE NAME public.itest3_a_seq
    START WITH 7
    INCREMENT BY 5
    NO MINVALUE
    NO MAXVALUE
    CACHE 1
);


--
-- Name: itest3_c_seq; Type: SEQUENCE; Schema: public; Owner: ashutoshpg
--

ALTER TABLE public.itest3 ALTER COLUMN c ADD GENERATED ALWAYS AS IDENTITY (
    SEQUENCE NAME public.itest3_c_seq
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1
);


--
-- Name: itest4; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.itest4 (
    a integer,
    b text DEFAULT ''::text
);


ALTER TABLE public.itest4 OWNER TO ashutoshpg;

--
-- Name: itest5; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.itest5 (
    a integer NOT NULL,
    b text
);


ALTER TABLE public.itest5 OWNER TO ashutoshpg;

--
-- Name: itest5_a_seq; Type: SEQUENCE; Schema: public; Owner: ashutoshpg
--

CREATE SEQUENCE public.itest5_a_seq
    AS integer
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1;


ALTER SEQUENCE public.itest5_a_seq OWNER TO ashutoshpg;

--
-- Name: itest5_a_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: ashutoshpg
--

ALTER SEQUENCE public.itest5_a_seq OWNED BY public.itest5.a;


--
-- Name: itest6; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.itest6 (
    a integer NOT NULL,
    b text
);


ALTER TABLE public.itest6 OWNER TO ashutoshpg;

--
-- Name: itest6_a_seq; Type: SEQUENCE; Schema: public; Owner: ashutoshpg
--

ALTER TABLE public.itest6 ALTER COLUMN a ADD GENERATED BY DEFAULT AS IDENTITY (
    SEQUENCE NAME public.itest6_a_seq
    START WITH 100
    INCREMENT BY 2
    NO MINVALUE
    NO MAXVALUE
    CACHE 1
);


--
-- Name: itest7; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.itest7 (
    a integer NOT NULL
);


ALTER TABLE public.itest7 OWNER TO ashutoshpg;

--
-- Name: itest7a; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.itest7a (
    b text
)
INHERITS (public.itest7);


ALTER TABLE public.itest7a OWNER TO ashutoshpg;

--
-- Name: itest7b; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.itest7b (
    a integer
);


ALTER TABLE public.itest7b OWNER TO ashutoshpg;

--
-- Name: itest7c; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.itest7c (
    a integer NOT NULL
)
INHERITS (public.itest7b);


ALTER TABLE public.itest7c OWNER TO ashutoshpg;

--
-- Name: itest7c_a_seq; Type: SEQUENCE; Schema: public; Owner: ashutoshpg
--

ALTER TABLE public.itest7c ALTER COLUMN a ADD GENERATED ALWAYS AS IDENTITY (
    SEQUENCE NAME public.itest7c_a_seq
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1
);


--
-- Name: itest7d; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.itest7d (
    a integer NOT NULL
);


ALTER TABLE public.itest7d OWNER TO ashutoshpg;

--
-- Name: itest7d_a_seq; Type: SEQUENCE; Schema: public; Owner: ashutoshpg
--

ALTER TABLE public.itest7d ALTER COLUMN a ADD GENERATED ALWAYS AS IDENTITY (
    SEQUENCE NAME public.itest7d_a_seq
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1
);


--
-- Name: itest7e; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.itest7e (
)
INHERITS (public.itest7d);


ALTER TABLE public.itest7e OWNER TO ashutoshpg;

--
-- Name: itest9; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.itest9 (
    a integer NOT NULL,
    b text,
    c bigint
);


ALTER TABLE public.itest9 OWNER TO ashutoshpg;

--
-- Name: itest9_a_seq; Type: SEQUENCE; Schema: public; Owner: ashutoshpg
--

ALTER TABLE public.itest9 ALTER COLUMN a ADD GENERATED ALWAYS AS IDENTITY (
    SEQUENCE NAME public.itest9_a_seq
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1
);


--
-- Name: kd_point_tbl; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.kd_point_tbl (
    p point
);


ALTER TABLE public.kd_point_tbl OWNER TO ashutoshpg;

--
-- Name: key_dependent_view; Type: VIEW; Schema: public; Owner: ashutoshpg
--

CREATE VIEW public.key_dependent_view AS
SELECT
    NULL::integer AS key,
    NULL::character varying(20) AS data;


ALTER VIEW public.key_dependent_view OWNER TO ashutoshpg;

--
-- Name: key_dependent_view_no_cols; Type: VIEW; Schema: public; Owner: ashutoshpg
--

CREATE VIEW public.key_dependent_view_no_cols AS
SELECT;


ALTER VIEW public.key_dependent_view_no_cols OWNER TO ashutoshpg;

--
-- Name: onek; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.onek (
    unique1 integer,
    unique2 integer,
    two integer,
    four integer,
    ten integer,
    twenty integer,
    hundred integer,
    thousand integer,
    twothousand integer,
    fivethous integer,
    tenthous integer,
    odd integer,
    even integer,
    stringu1 name,
    stringu2 name,
    string4 name
);


ALTER TABLE public.onek OWNER TO ashutoshpg;

--
-- Name: limit_thousand_v_1; Type: VIEW; Schema: public; Owner: ashutoshpg
--

CREATE VIEW public.limit_thousand_v_1 AS
 SELECT thousand
   FROM public.onek
  WHERE (thousand < 995)
  ORDER BY thousand
 OFFSET 10
 FETCH FIRST 5 ROWS WITH TIES;


ALTER VIEW public.limit_thousand_v_1 OWNER TO ashutoshpg;

--
-- Name: limit_thousand_v_2; Type: VIEW; Schema: public; Owner: ashutoshpg
--

CREATE VIEW public.limit_thousand_v_2 AS
 SELECT thousand
   FROM public.onek
  WHERE (thousand < 995)
  ORDER BY thousand
 OFFSET 10
 LIMIT 5;


ALTER VIEW public.limit_thousand_v_2 OWNER TO ashutoshpg;

--
-- Name: limit_thousand_v_3; Type: VIEW; Schema: public; Owner: ashutoshpg
--

CREATE VIEW public.limit_thousand_v_3 AS
 SELECT thousand
   FROM public.onek
  WHERE (thousand < 995)
  ORDER BY thousand
 FETCH FIRST (NULL::integer + 1) ROWS WITH TIES;


ALTER VIEW public.limit_thousand_v_3 OWNER TO ashutoshpg;

--
-- Name: limit_thousand_v_4; Type: VIEW; Schema: public; Owner: ashutoshpg
--

CREATE VIEW public.limit_thousand_v_4 AS
 SELECT thousand
   FROM public.onek
  WHERE (thousand < 995)
  ORDER BY thousand
 LIMIT ALL;


ALTER VIEW public.limit_thousand_v_4 OWNER TO ashutoshpg;

--
-- Name: line_tbl; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.line_tbl (
    s line
);


ALTER TABLE public.line_tbl OWNER TO ashutoshpg;

--
-- Name: log_table; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.log_table (
    tstamp timestamp without time zone DEFAULT (timeofday())::timestamp without time zone
);


ALTER TABLE public.log_table OWNER TO ashutoshpg;

--
-- Name: lseg_tbl; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.lseg_tbl (
    s lseg
);


ALTER TABLE public.lseg_tbl OWNER TO ashutoshpg;

--
-- Name: main_table; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.main_table (
    a integer,
    b integer
);


ALTER TABLE public.main_table OWNER TO ashutoshpg;

--
-- Name: mcv_lists; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.mcv_lists (
    filler1 text,
    filler2 numeric,
    a integer,
    b character varying,
    filler3 date,
    c numeric,
    d character varying(64),
    ia integer[]
)
WITH (autovacuum_enabled=off);


ALTER TABLE public.mcv_lists OWNER TO ashutoshpg;

--
-- Name: mcv_lists_arrays; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.mcv_lists_arrays (
    a text[],
    b numeric[],
    c integer[]
)
WITH (autovacuum_enabled=off);


ALTER TABLE public.mcv_lists_arrays OWNER TO ashutoshpg;

--
-- Name: mcv_lists_bool; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.mcv_lists_bool (
    a boolean,
    b boolean,
    c boolean
)
WITH (autovacuum_enabled=off);


ALTER TABLE public.mcv_lists_bool OWNER TO ashutoshpg;

--
-- Name: mic_inputs; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.mic_inputs (
    inbytes bytea,
    description text
);


ALTER TABLE public.mic_inputs OWNER TO ashutoshpg;

--
-- Name: mlparted; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.mlparted (
    a integer,
    b integer,
    c text
)
PARTITION BY RANGE (a, b);


ALTER TABLE public.mlparted OWNER TO ashutoshpg;

--
-- Name: mlparted1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.mlparted1 (
    b integer NOT NULL,
    a integer NOT NULL,
    c text
)
PARTITION BY RANGE (((b + 0)));


ALTER TABLE public.mlparted1 OWNER TO ashutoshpg;

--
-- Name: mlparted11; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.mlparted11 (
    b integer CONSTRAINT mlparted1_b_not_null NOT NULL,
    a integer NOT NULL,
    c text
);


ALTER TABLE public.mlparted11 OWNER TO ashutoshpg;

--
-- Name: mlparted12; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.mlparted12 (
    b integer CONSTRAINT mlparted1_b_not_null NOT NULL,
    a integer CONSTRAINT mlparted1_a_not_null NOT NULL,
    c text
);


ALTER TABLE public.mlparted12 OWNER TO ashutoshpg;

--
-- Name: mlparted2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.mlparted2 (
    b integer NOT NULL,
    a integer NOT NULL,
    c text
);


ALTER TABLE public.mlparted2 OWNER TO ashutoshpg;

--
-- Name: mlparted3; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.mlparted3 (
    a integer,
    b integer,
    c text
);


ALTER TABLE public.mlparted3 OWNER TO ashutoshpg;

--
-- Name: mlparted4; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.mlparted4 (
    b integer,
    a integer NOT NULL,
    c text
);


ALTER TABLE public.mlparted4 OWNER TO ashutoshpg;

--
-- Name: mlparted_def; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.mlparted_def (
    a integer,
    b integer,
    c text
)
PARTITION BY RANGE (a);


ALTER TABLE public.mlparted_def OWNER TO ashutoshpg;

--
-- Name: mlparted_def1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.mlparted_def1 (
    a integer,
    b integer,
    c text
);


ALTER TABLE public.mlparted_def1 OWNER TO ashutoshpg;

--
-- Name: mlparted_def2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.mlparted_def2 (
    a integer,
    b integer,
    c text
);


ALTER TABLE public.mlparted_def2 OWNER TO ashutoshpg;

--
-- Name: mlparted_defd; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.mlparted_defd (
    a integer,
    b integer,
    c text
);


ALTER TABLE public.mlparted_defd OWNER TO ashutoshpg;

--
-- Name: money_data; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.money_data (
    m money
);


ALTER TABLE public.money_data OWNER TO ashutoshpg;

--
-- Name: mvtest_tvv; Type: VIEW; Schema: public; Owner: ashutoshpg
--

CREATE VIEW public.mvtest_tvv AS
 SELECT sum(totamt) AS grandtot
   FROM public.mvtest_tv;


ALTER VIEW public.mvtest_tvv OWNER TO ashutoshpg;

--
-- Name: mvtest_tvvm; Type: MATERIALIZED VIEW; Schema: public; Owner: ashutoshpg
--

CREATE MATERIALIZED VIEW public.mvtest_tvvm AS
 SELECT grandtot
   FROM public.mvtest_tvv
  WITH NO DATA;


ALTER MATERIALIZED VIEW public.mvtest_tvvm OWNER TO ashutoshpg;

--
-- Name: mvtest_tvvmv; Type: VIEW; Schema: public; Owner: ashutoshpg
--

CREATE VIEW public.mvtest_tvvmv AS
 SELECT grandtot
   FROM public.mvtest_tvvm;


ALTER VIEW public.mvtest_tvvmv OWNER TO ashutoshpg;

--
-- Name: mvtest_bb; Type: MATERIALIZED VIEW; Schema: public; Owner: ashutoshpg
--

CREATE MATERIALIZED VIEW public.mvtest_bb AS
 SELECT grandtot
   FROM public.mvtest_tvvmv
  WITH NO DATA;


ALTER MATERIALIZED VIEW public.mvtest_bb OWNER TO ashutoshpg;

--
-- Name: mvtest_tm; Type: MATERIALIZED VIEW; Schema: public; Owner: ashutoshpg
--

CREATE MATERIALIZED VIEW public.mvtest_tm AS
 SELECT type,
    sum(amt) AS totamt
   FROM public.mvtest_t
  GROUP BY type
  WITH NO DATA;


ALTER MATERIALIZED VIEW public.mvtest_tm OWNER TO ashutoshpg;

--
-- Name: mvtest_tmm; Type: MATERIALIZED VIEW; Schema: public; Owner: ashutoshpg
--

CREATE MATERIALIZED VIEW public.mvtest_tmm AS
 SELECT sum(totamt) AS grandtot
   FROM public.mvtest_tm
  WITH NO DATA;


ALTER MATERIALIZED VIEW public.mvtest_tmm OWNER TO ashutoshpg;

--
-- Name: mvtest_tvmm; Type: MATERIALIZED VIEW; Schema: public; Owner: ashutoshpg
--

CREATE MATERIALIZED VIEW public.mvtest_tvmm AS
 SELECT sum(totamt) AS grandtot
   FROM mvtest_mvschema.mvtest_tvm
  WITH NO DATA;


ALTER MATERIALIZED VIEW public.mvtest_tvmm OWNER TO ashutoshpg;

--
-- Name: my_credit_card_normal; Type: VIEW; Schema: public; Owner: ashutoshpg
--

CREATE VIEW public.my_credit_card_normal AS
 SELECT l.cid,
    l.name,
    l.tel,
    l.passwd,
    r.cnum,
    r.climit
   FROM (public.customer l
     JOIN public.credit_card r USING (cid))
  WHERE (l.name = CURRENT_USER);


ALTER VIEW public.my_credit_card_normal OWNER TO ashutoshpg;

--
-- Name: my_credit_card_secure; Type: VIEW; Schema: public; Owner: ashutoshpg
--

CREATE VIEW public.my_credit_card_secure WITH (security_barrier='true') AS
 SELECT l.cid,
    l.name,
    l.tel,
    l.passwd,
    r.cnum,
    r.climit
   FROM (public.customer l
     JOIN public.credit_card r USING (cid))
  WHERE (l.name = CURRENT_USER);


ALTER VIEW public.my_credit_card_secure OWNER TO ashutoshpg;

--
-- Name: my_credit_card_usage_normal; Type: VIEW; Schema: public; Owner: ashutoshpg
--

CREATE VIEW public.my_credit_card_usage_normal AS
 SELECT l.cid,
    l.name,
    l.tel,
    l.passwd,
    l.cnum,
    l.climit,
    r.ymd,
    r.usage
   FROM (public.my_credit_card_secure l
     JOIN public.credit_usage r USING (cid));


ALTER VIEW public.my_credit_card_usage_normal OWNER TO ashutoshpg;

--
-- Name: my_credit_card_usage_secure; Type: VIEW; Schema: public; Owner: ashutoshpg
--

CREATE VIEW public.my_credit_card_usage_secure WITH (security_barrier='true') AS
 SELECT l.cid,
    l.name,
    l.tel,
    l.passwd,
    l.cnum,
    l.climit,
    r.ymd,
    r.usage
   FROM (public.my_credit_card_secure l
     JOIN public.credit_usage r USING (cid));


ALTER VIEW public.my_credit_card_usage_secure OWNER TO ashutoshpg;

--
-- Name: my_property_normal; Type: VIEW; Schema: public; Owner: ashutoshpg
--

CREATE VIEW public.my_property_normal WITH (security_barrier='true') AS
 SELECT cid,
    name,
    tel,
    passwd
   FROM public.customer
  WHERE (name = CURRENT_USER);


ALTER VIEW public.my_property_normal OWNER TO ashutoshpg;

--
-- Name: my_property_secure; Type: VIEW; Schema: public; Owner: ashutoshpg
--

CREATE VIEW public.my_property_secure WITH (security_barrier='false') AS
 SELECT cid,
    name,
    tel,
    passwd
   FROM public.customer
  WHERE (name = CURRENT_USER);


ALTER VIEW public.my_property_secure OWNER TO ashutoshpg;

--
-- Name: ndistinct; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.ndistinct (
    filler1 text,
    filler2 numeric,
    a integer,
    b integer,
    filler3 date,
    c integer,
    d integer
)
WITH (autovacuum_enabled=off);


ALTER TABLE public.ndistinct OWNER TO ashutoshpg;

--
-- Name: notnull_tbl3; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.notnull_tbl3 (
    a integer NOT NULL,
    b integer NOT NULL,
    CONSTRAINT notnull_tbl3_a_check CHECK ((a IS NOT NULL))
);


ALTER TABLE public.notnull_tbl3 OWNER TO ashutoshpg;

--
-- Name: notnull_tbl4; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.notnull_tbl4 (
    a integer NOT NULL
);


ALTER TABLE public.notnull_tbl4 OWNER TO ashutoshpg;

--
-- Name: notnull_tbl4_cld; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.notnull_tbl4_cld (
)
INHERITS (public.notnull_tbl4);


ALTER TABLE public.notnull_tbl4_cld OWNER TO ashutoshpg;

--
-- Name: notnull_tbl4_cld2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.notnull_tbl4_cld2 (
)
INHERITS (public.notnull_tbl4);
ALTER TABLE ONLY public.notnull_tbl4_cld2 ALTER COLUMN a SET NOT NULL;


ALTER TABLE public.notnull_tbl4_cld2 OWNER TO ashutoshpg;

--
-- Name: notnull_tbl4_cld3; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.notnull_tbl4_cld3 (
)
INHERITS (public.notnull_tbl4);
ALTER TABLE ONLY public.notnull_tbl4_cld3 ADD CONSTRAINT a_nn NOT NULL a;


ALTER TABLE public.notnull_tbl4_cld3 OWNER TO ashutoshpg;

--
-- Name: notnull_tbl4_lk; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.notnull_tbl4_lk (
    a integer CONSTRAINT notnull_tbl4_a_not_null NOT NULL
);


ALTER TABLE public.notnull_tbl4_lk OWNER TO ashutoshpg;

--
-- Name: notnull_tbl4_lk2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.notnull_tbl4_lk2 (
    a integer CONSTRAINT notnull_tbl4_a_not_null NOT NULL
);


ALTER TABLE public.notnull_tbl4_lk2 OWNER TO ashutoshpg;

--
-- Name: notnull_tbl4_lk3; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.notnull_tbl4_lk3 (
    a integer CONSTRAINT a_nn NOT NULL
);


ALTER TABLE public.notnull_tbl4_lk3 OWNER TO ashutoshpg;

--
-- Name: notnull_tbl5; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.notnull_tbl5 (
    a integer,
    b integer
);


ALTER TABLE public.notnull_tbl5 OWNER TO ashutoshpg;

--
-- Name: notnull_tbl5_child; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.notnull_tbl5_child (
)
INHERITS (public.notnull_tbl5);
ALTER TABLE ONLY public.notnull_tbl5_child ADD CONSTRAINT ann NOT NULL a;
ALTER TABLE ONLY public.notnull_tbl5_child ADD CONSTRAINT bnn NOT NULL b;


ALTER TABLE public.notnull_tbl5_child OWNER TO ashutoshpg;

--
-- Name: notnull_tbl6; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.notnull_tbl6 (
    a integer,
    b integer,
    CONSTRAINT notnull_tbl6_a_check CHECK ((a > 0))
)
PARTITION BY LIST (a);


ALTER TABLE public.notnull_tbl6 OWNER TO ashutoshpg;

--
-- Name: notnull_tbl6_1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.notnull_tbl6_1 (
    a integer CONSTRAINT ann NOT NULL,
    b integer CONSTRAINT bnn NOT NULL,
    CONSTRAINT notnull_tbl6_a_check CHECK ((a > 0))
);


ALTER TABLE public.notnull_tbl6_1 OWNER TO ashutoshpg;

--
-- Name: num_data; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.num_data (
    id integer,
    val numeric(210,10)
);


ALTER TABLE public.num_data OWNER TO ashutoshpg;

--
-- Name: num_exp_add; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.num_exp_add (
    id1 integer,
    id2 integer,
    expected numeric(210,10)
);


ALTER TABLE public.num_exp_add OWNER TO ashutoshpg;

--
-- Name: num_exp_div; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.num_exp_div (
    id1 integer,
    id2 integer,
    expected numeric(210,10)
);


ALTER TABLE public.num_exp_div OWNER TO ashutoshpg;

--
-- Name: num_exp_ln; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.num_exp_ln (
    id integer,
    expected numeric(210,10)
);


ALTER TABLE public.num_exp_ln OWNER TO ashutoshpg;

--
-- Name: num_exp_log10; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.num_exp_log10 (
    id integer,
    expected numeric(210,10)
);


ALTER TABLE public.num_exp_log10 OWNER TO ashutoshpg;

--
-- Name: num_exp_mul; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.num_exp_mul (
    id1 integer,
    id2 integer,
    expected numeric(210,10)
);


ALTER TABLE public.num_exp_mul OWNER TO ashutoshpg;

--
-- Name: num_exp_power_10_ln; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.num_exp_power_10_ln (
    id integer,
    expected numeric(210,10)
);


ALTER TABLE public.num_exp_power_10_ln OWNER TO ashutoshpg;

--
-- Name: num_exp_sqrt; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.num_exp_sqrt (
    id integer,
    expected numeric(210,10)
);


ALTER TABLE public.num_exp_sqrt OWNER TO ashutoshpg;

--
-- Name: num_exp_sub; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.num_exp_sub (
    id1 integer,
    id2 integer,
    expected numeric(210,10)
);


ALTER TABLE public.num_exp_sub OWNER TO ashutoshpg;

--
-- Name: num_input_test; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.num_input_test (
    n1 numeric
);


ALTER TABLE public.num_input_test OWNER TO ashutoshpg;

--
-- Name: num_result; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.num_result (
    id1 integer,
    id2 integer,
    result numeric(210,10)
);


ALTER TABLE public.num_result OWNER TO ashutoshpg;

--
-- Name: num_typemod_test; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.num_typemod_test (
    millions numeric(3,-6),
    thousands numeric(3,-3),
    units numeric(3,0),
    thousandths numeric(3,3),
    millionths numeric(3,6)
);


ALTER TABLE public.num_typemod_test OWNER TO ashutoshpg;

--
-- Name: nummultirange_test; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.nummultirange_test (
    nmr nummultirange
);


ALTER TABLE public.nummultirange_test OWNER TO ashutoshpg;

--
-- Name: numrange_test; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.numrange_test (
    nr numrange
);


ALTER TABLE public.numrange_test OWNER TO ashutoshpg;

--
-- Name: nums; Type: VIEW; Schema: public; Owner: ashutoshpg
--

CREATE VIEW public.nums AS
 WITH RECURSIVE nums(n) AS (
         VALUES (1)
        UNION ALL
         SELECT (nums_1.n + 1)
           FROM nums nums_1
          WHERE (nums_1.n < 6)
        )
 SELECT n
   FROM nums;


ALTER VIEW public.nums OWNER TO ashutoshpg;

--
-- Name: nv_parent; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.nv_parent (
    d date,
    CONSTRAINT nv_parent_check CHECK (false) NO INHERIT
);


ALTER TABLE public.nv_parent OWNER TO ashutoshpg;

--
-- Name: nv_child_2009; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.nv_child_2009 (
    CONSTRAINT nv_child_2009_d_check CHECK (((d >= '2009-01-01'::date) AND (d <= '2009-12-31'::date)))
)
INHERITS (public.nv_parent);


ALTER TABLE public.nv_child_2009 OWNER TO ashutoshpg;

--
-- Name: nv_child_2010; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.nv_child_2010 (
)
INHERITS (public.nv_parent);


ALTER TABLE public.nv_child_2010 OWNER TO ashutoshpg;

--
-- Name: nv_child_2011; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.nv_child_2011 (
    CONSTRAINT nv_child_2011_d_check CHECK (((d >= '2011-01-01'::date) AND (d <= '2011-12-31'::date)))
)
INHERITS (public.nv_parent);


ALTER TABLE public.nv_child_2011 OWNER TO ashutoshpg;

--
-- Name: onek2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.onek2 (
    unique1 integer,
    unique2 integer,
    two integer,
    four integer,
    ten integer,
    twenty integer,
    hundred integer,
    thousand integer,
    twothousand integer,
    fivethous integer,
    tenthous integer,
    odd integer,
    even integer,
    stringu1 name,
    stringu2 name,
    string4 name
);


ALTER TABLE public.onek2 OWNER TO ashutoshpg;

--
-- Name: pagg_tab; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.pagg_tab (
    a integer,
    b integer,
    c text,
    d integer
)
PARTITION BY LIST (c);


ALTER TABLE public.pagg_tab OWNER TO ashutoshpg;

--
-- Name: pagg_tab1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.pagg_tab1 (
    x integer,
    y integer
)
PARTITION BY RANGE (x);


ALTER TABLE public.pagg_tab1 OWNER TO ashutoshpg;

--
-- Name: pagg_tab1_p1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.pagg_tab1_p1 (
    x integer,
    y integer
);


ALTER TABLE public.pagg_tab1_p1 OWNER TO ashutoshpg;

--
-- Name: pagg_tab1_p2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.pagg_tab1_p2 (
    x integer,
    y integer
);


ALTER TABLE public.pagg_tab1_p2 OWNER TO ashutoshpg;

--
-- Name: pagg_tab1_p3; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.pagg_tab1_p3 (
    x integer,
    y integer
);


ALTER TABLE public.pagg_tab1_p3 OWNER TO ashutoshpg;

--
-- Name: pagg_tab2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.pagg_tab2 (
    x integer,
    y integer
)
PARTITION BY RANGE (y);


ALTER TABLE public.pagg_tab2 OWNER TO ashutoshpg;

--
-- Name: pagg_tab2_p1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.pagg_tab2_p1 (
    x integer,
    y integer
);


ALTER TABLE public.pagg_tab2_p1 OWNER TO ashutoshpg;

--
-- Name: pagg_tab2_p2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.pagg_tab2_p2 (
    x integer,
    y integer
);


ALTER TABLE public.pagg_tab2_p2 OWNER TO ashutoshpg;

--
-- Name: pagg_tab2_p3; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.pagg_tab2_p3 (
    x integer,
    y integer
);


ALTER TABLE public.pagg_tab2_p3 OWNER TO ashutoshpg;

--
-- Name: pagg_tab_m; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.pagg_tab_m (
    a integer,
    b integer,
    c integer
)
PARTITION BY RANGE (a, (((a + b) / 2)));


ALTER TABLE public.pagg_tab_m OWNER TO ashutoshpg;

--
-- Name: pagg_tab_m_p1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.pagg_tab_m_p1 (
    a integer,
    b integer,
    c integer
);


ALTER TABLE public.pagg_tab_m_p1 OWNER TO ashutoshpg;

--
-- Name: pagg_tab_m_p2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.pagg_tab_m_p2 (
    a integer,
    b integer,
    c integer
);


ALTER TABLE public.pagg_tab_m_p2 OWNER TO ashutoshpg;

--
-- Name: pagg_tab_m_p3; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.pagg_tab_m_p3 (
    a integer,
    b integer,
    c integer
);


ALTER TABLE public.pagg_tab_m_p3 OWNER TO ashutoshpg;

--
-- Name: pagg_tab_ml; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.pagg_tab_ml (
    a integer,
    b integer,
    c text
)
PARTITION BY RANGE (a);


ALTER TABLE public.pagg_tab_ml OWNER TO ashutoshpg;

--
-- Name: pagg_tab_ml_p1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.pagg_tab_ml_p1 (
    a integer,
    b integer,
    c text
);


ALTER TABLE public.pagg_tab_ml_p1 OWNER TO ashutoshpg;

--
-- Name: pagg_tab_ml_p2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.pagg_tab_ml_p2 (
    a integer,
    b integer,
    c text
)
PARTITION BY LIST (c);


ALTER TABLE public.pagg_tab_ml_p2 OWNER TO ashutoshpg;

--
-- Name: pagg_tab_ml_p2_s1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.pagg_tab_ml_p2_s1 (
    a integer,
    b integer,
    c text
);


ALTER TABLE public.pagg_tab_ml_p2_s1 OWNER TO ashutoshpg;

--
-- Name: pagg_tab_ml_p2_s2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.pagg_tab_ml_p2_s2 (
    a integer,
    b integer,
    c text
);


ALTER TABLE public.pagg_tab_ml_p2_s2 OWNER TO ashutoshpg;

--
-- Name: pagg_tab_ml_p3; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.pagg_tab_ml_p3 (
    b integer,
    c text,
    a integer
)
PARTITION BY RANGE (b);


ALTER TABLE public.pagg_tab_ml_p3 OWNER TO ashutoshpg;

--
-- Name: pagg_tab_ml_p3_s1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.pagg_tab_ml_p3_s1 (
    c text,
    a integer,
    b integer
);


ALTER TABLE public.pagg_tab_ml_p3_s1 OWNER TO ashutoshpg;

--
-- Name: pagg_tab_ml_p3_s2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.pagg_tab_ml_p3_s2 (
    b integer,
    c text,
    a integer
);


ALTER TABLE public.pagg_tab_ml_p3_s2 OWNER TO ashutoshpg;

--
-- Name: pagg_tab_p1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.pagg_tab_p1 (
    a integer,
    b integer,
    c text,
    d integer
);


ALTER TABLE public.pagg_tab_p1 OWNER TO ashutoshpg;

--
-- Name: pagg_tab_p2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.pagg_tab_p2 (
    a integer,
    b integer,
    c text,
    d integer
);


ALTER TABLE public.pagg_tab_p2 OWNER TO ashutoshpg;

--
-- Name: pagg_tab_p3; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.pagg_tab_p3 (
    a integer,
    b integer,
    c text,
    d integer
);


ALTER TABLE public.pagg_tab_p3 OWNER TO ashutoshpg;

--
-- Name: pagg_tab_para; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.pagg_tab_para (
    x integer,
    y integer
)
PARTITION BY RANGE (x);


ALTER TABLE public.pagg_tab_para OWNER TO ashutoshpg;

--
-- Name: pagg_tab_para_p1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.pagg_tab_para_p1 (
    x integer,
    y integer
)
WITH (parallel_workers='0');


ALTER TABLE public.pagg_tab_para_p1 OWNER TO ashutoshpg;

--
-- Name: pagg_tab_para_p2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.pagg_tab_para_p2 (
    x integer,
    y integer
)
WITH (parallel_workers='0');


ALTER TABLE public.pagg_tab_para_p2 OWNER TO ashutoshpg;

--
-- Name: pagg_tab_para_p3; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.pagg_tab_para_p3 (
    x integer,
    y integer
)
WITH (parallel_workers='0');


ALTER TABLE public.pagg_tab_para_p3 OWNER TO ashutoshpg;

--
-- Name: parallel_vacuum_table; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.parallel_vacuum_table (
    a integer
)
WITH (autovacuum_enabled=off);


ALTER TABLE public.parallel_vacuum_table OWNER TO ashutoshpg;

--
-- Name: part; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.part (
    a integer,
    b integer
)
PARTITION BY LIST (a);


ALTER TABLE public.part OWNER TO ashutoshpg;

--
-- Name: parted_self_fk; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.parted_self_fk (
    id bigint NOT NULL,
    id_abc bigint
)
PARTITION BY RANGE (id);


ALTER TABLE public.parted_self_fk OWNER TO ashutoshpg;

--
-- Name: part1_self_fk; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.part1_self_fk (
    id bigint NOT NULL,
    id_abc bigint
);


ALTER TABLE public.part1_self_fk OWNER TO ashutoshpg;

--
-- Name: part2_self_fk; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.part2_self_fk (
    id bigint CONSTRAINT parted_self_fk_id_not_null NOT NULL,
    id_abc bigint
);


ALTER TABLE public.part2_self_fk OWNER TO ashutoshpg;

--
-- Name: part3_self_fk; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.part3_self_fk (
    id bigint NOT NULL,
    id_abc bigint
)
PARTITION BY RANGE (id);


ALTER TABLE public.part3_self_fk OWNER TO ashutoshpg;

--
-- Name: part32_self_fk; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.part32_self_fk (
    id bigint CONSTRAINT part3_self_fk_id_not_null NOT NULL,
    id_abc bigint
);


ALTER TABLE public.part32_self_fk OWNER TO ashutoshpg;

--
-- Name: part33_self_fk; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.part33_self_fk (
    id bigint NOT NULL,
    id_abc bigint
);


ALTER TABLE public.part33_self_fk OWNER TO ashutoshpg;

--
-- Name: part_7; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.part_7 (
    a integer,
    b character(1)
)
PARTITION BY LIST (b);


ALTER TABLE public.part_7 OWNER TO ashutoshpg;

--
-- Name: part_7_a_null; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.part_7_a_null (
    a integer,
    b character(1),
    CONSTRAINT check_b CHECK (((b IS NULL) OR (b = 'a'::bpchar)))
);


ALTER TABLE public.part_7_a_null OWNER TO ashutoshpg;

--
-- Name: part_p1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.part_p1 (
    a integer,
    b integer
);


ALTER TABLE public.part_p1 OWNER TO ashutoshpg;

--
-- Name: part_p2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.part_p2 (
    a integer,
    b integer
)
PARTITION BY RANGE (a);


ALTER TABLE public.part_p2 OWNER TO ashutoshpg;

--
-- Name: part_p2_p1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.part_p2_p1 (
    a integer,
    b integer
);


ALTER TABLE public.part_p2_p1 OWNER TO ashutoshpg;

--
-- Name: part_rev; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.part_rev (
    b integer,
    a integer
);


ALTER TABLE public.part_rev OWNER TO ashutoshpg;

--
-- Name: part_rp; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.part_rp (
    a integer,
    CONSTRAINT part_rp_a_check CHECK (((a IS NOT NULL) AND (a >= 0) AND (a < 100)))
);


ALTER TABLE public.part_rp OWNER TO ashutoshpg;

--
-- Name: part_rp100; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.part_rp100 (
    a integer,
    CONSTRAINT part_rp100_a_check CHECK (((a >= 123) AND (a < 133) AND (a IS NOT NULL)))
);


ALTER TABLE public.part_rp100 OWNER TO ashutoshpg;

--
-- Name: partr_def2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.partr_def2 (
    a integer CONSTRAINT part1_a_not_null NOT NULL,
    b integer CONSTRAINT part1_b_not_null NOT NULL,
    CONSTRAINT part1_a_check CHECK ((a = 1)),
    CONSTRAINT part1_b_check CHECK (((b >= 1) AND (b <= 10)))
);


ALTER TABLE public.partr_def2 OWNER TO ashutoshpg;

--
-- Name: past_inh_parent; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.past_inh_parent (
);


ALTER TABLE public.past_inh_parent OWNER TO ashutoshpg;

--
-- Name: past_parted; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.past_parted (
    i integer
)
PARTITION BY LIST (i);


ALTER TABLE public.past_parted OWNER TO ashutoshpg;

--
-- Name: path_tbl; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.path_tbl (
    f1 path
);


ALTER TABLE public.path_tbl OWNER TO ashutoshpg;

--
-- Name: perm_part_child; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.perm_part_child (
    a integer
);


ALTER TABLE public.perm_part_child OWNER TO ashutoshpg;

--
-- Name: persons; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.persons OF public.person_type;


ALTER TABLE public.persons OWNER TO ashutoshpg;

--
-- Name: persons2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.persons2 OF public.person_type (
    id NOT NULL
);


ALTER TABLE public.persons2 OWNER TO ashutoshpg;

--
-- Name: persons3; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.persons3 OF public.person_type (
    id NOT NULL,
    name DEFAULT ''::text NOT NULL
);


ALTER TABLE public.persons3 OWNER TO ashutoshpg;

--
-- Name: pfield; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.pfield (
    name text,
    comment text
);


ALTER TABLE public.pfield OWNER TO ashutoshpg;

--
-- Name: pslot; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.pslot (
    slotname character(20),
    pfname text,
    slotlink character(20),
    backlink character(20)
);


ALTER TABLE public.pslot OWNER TO ashutoshpg;

--
-- Name: pfield_v1; Type: VIEW; Schema: public; Owner: ashutoshpg
--

CREATE VIEW public.pfield_v1 AS
 SELECT pfname,
    slotname,
    public.pslot_backlink_view(slotname) AS backside,
    public.pslot_slotlink_view(slotname) AS patch
   FROM public.pslot pf;


ALTER VIEW public.pfield_v1 OWNER TO ashutoshpg;

--
-- Name: phone; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.phone (
    slotname character(20),
    comment text,
    slotlink character(20)
);


ALTER TABLE public.phone OWNER TO ashutoshpg;

--
-- Name: pht1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.pht1 (
    a integer,
    b integer,
    c text
)
PARTITION BY HASH (c);


ALTER TABLE public.pht1 OWNER TO ashutoshpg;

--
-- Name: pht1_e; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.pht1_e (
    a integer,
    b integer,
    c text
)
PARTITION BY HASH (ltrim(c, 'A'::text));


ALTER TABLE public.pht1_e OWNER TO ashutoshpg;

--
-- Name: pht1_e_p1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.pht1_e_p1 (
    a integer,
    b integer,
    c text
);


ALTER TABLE public.pht1_e_p1 OWNER TO ashutoshpg;

--
-- Name: pht1_e_p2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.pht1_e_p2 (
    a integer,
    b integer,
    c text
);


ALTER TABLE public.pht1_e_p2 OWNER TO ashutoshpg;

--
-- Name: pht1_e_p3; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.pht1_e_p3 (
    a integer,
    b integer,
    c text
);


ALTER TABLE public.pht1_e_p3 OWNER TO ashutoshpg;

--
-- Name: pht1_p1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.pht1_p1 (
    a integer,
    b integer,
    c text
);


ALTER TABLE public.pht1_p1 OWNER TO ashutoshpg;

--
-- Name: pht1_p2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.pht1_p2 (
    a integer,
    b integer,
    c text
);


ALTER TABLE public.pht1_p2 OWNER TO ashutoshpg;

--
-- Name: pht1_p3; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.pht1_p3 (
    a integer,
    b integer,
    c text
);


ALTER TABLE public.pht1_p3 OWNER TO ashutoshpg;

--
-- Name: pht2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.pht2 (
    a integer,
    b integer,
    c text
)
PARTITION BY HASH (c);


ALTER TABLE public.pht2 OWNER TO ashutoshpg;

--
-- Name: pht2_p1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.pht2_p1 (
    a integer,
    b integer,
    c text
);


ALTER TABLE public.pht2_p1 OWNER TO ashutoshpg;

--
-- Name: pht2_p2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.pht2_p2 (
    a integer,
    b integer,
    c text
);


ALTER TABLE public.pht2_p2 OWNER TO ashutoshpg;

--
-- Name: pht2_p3; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.pht2_p3 (
    a integer,
    b integer,
    c text
);


ALTER TABLE public.pht2_p3 OWNER TO ashutoshpg;

--
-- Name: pitest1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.pitest1 (
    f1 date NOT NULL,
    f2 text,
    f3 bigint NOT NULL
)
PARTITION BY RANGE (f1);


ALTER TABLE public.pitest1 OWNER TO ashutoshpg;

--
-- Name: pitest1_f3_seq; Type: SEQUENCE; Schema: public; Owner: ashutoshpg
--

ALTER TABLE public.pitest1 ALTER COLUMN f3 ADD GENERATED ALWAYS AS IDENTITY (
    SEQUENCE NAME public.pitest1_f3_seq
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1
);


--
-- Name: pitest1_p1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.pitest1_p1 (
    f1 date CONSTRAINT pitest1_f1_not_null NOT NULL,
    f2 text,
    f3 bigint CONSTRAINT pitest1_f3_not_null NOT NULL
);


ALTER TABLE public.pitest1_p1 OWNER TO ashutoshpg;

--
-- Name: pitest1_p1_like; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.pitest1_p1_like (
    f1 date CONSTRAINT pitest1_f1_not_null NOT NULL,
    f2 text,
    f3 bigint CONSTRAINT pitest1_f3_not_null NOT NULL
);


ALTER TABLE public.pitest1_p1_like OWNER TO ashutoshpg;

--
-- Name: pitest1_p1_like_f3_seq; Type: SEQUENCE; Schema: public; Owner: ashutoshpg
--

ALTER TABLE public.pitest1_p1_like ALTER COLUMN f3 ADD GENERATED ALWAYS AS IDENTITY (
    SEQUENCE NAME public.pitest1_p1_like_f3_seq
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1
);


--
-- Name: pitest1_p2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.pitest1_p2 (
    f3 bigint CONSTRAINT pitest1_f3_not_null NOT NULL,
    f2 text,
    f1 date NOT NULL
);


ALTER TABLE public.pitest1_p2 OWNER TO ashutoshpg;

--
-- Name: pitest2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.pitest2 (
    f1 date NOT NULL,
    f2 text,
    f3 integer NOT NULL
)
PARTITION BY RANGE (f1);


ALTER TABLE public.pitest2 OWNER TO ashutoshpg;

--
-- Name: pitest2_f3_seq; Type: SEQUENCE; Schema: public; Owner: ashutoshpg
--

ALTER TABLE public.pitest2 ALTER COLUMN f3 ADD GENERATED BY DEFAULT AS IDENTITY (
    SEQUENCE NAME public.pitest2_f3_seq
    START WITH 1000
    INCREMENT BY 2
    NO MINVALUE
    NO MAXVALUE
    CACHE 1
);


--
-- Name: pitest2_p2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.pitest2_p2 (
    f1 date CONSTRAINT pitest2_f1_not_null NOT NULL,
    f2 text,
    f3 integer CONSTRAINT pitest2_f3_not_null NOT NULL
);


ALTER TABLE public.pitest2_p2 OWNER TO ashutoshpg;

--
-- Name: pline; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.pline (
    slotname character(20),
    phonenumber character(20),
    comment text,
    backlink character(20)
);


ALTER TABLE public.pline OWNER TO ashutoshpg;

--
-- Name: plt1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.plt1 (
    a integer,
    b integer,
    c text
)
PARTITION BY LIST (c);


ALTER TABLE public.plt1 OWNER TO ashutoshpg;

--
-- Name: plt1_e; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.plt1_e (
    a integer,
    b integer,
    c text
)
PARTITION BY LIST (ltrim(c, 'A'::text));


ALTER TABLE public.plt1_e OWNER TO ashutoshpg;

--
-- Name: plt1_e_p1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.plt1_e_p1 (
    a integer,
    b integer,
    c text
);


ALTER TABLE public.plt1_e_p1 OWNER TO ashutoshpg;

--
-- Name: plt1_e_p2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.plt1_e_p2 (
    a integer,
    b integer,
    c text
);


ALTER TABLE public.plt1_e_p2 OWNER TO ashutoshpg;

--
-- Name: plt1_e_p3; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.plt1_e_p3 (
    a integer,
    b integer,
    c text
);


ALTER TABLE public.plt1_e_p3 OWNER TO ashutoshpg;

--
-- Name: plt1_p1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.plt1_p1 (
    a integer,
    b integer,
    c text
);


ALTER TABLE public.plt1_p1 OWNER TO ashutoshpg;

--
-- Name: plt1_p2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.plt1_p2 (
    a integer,
    b integer,
    c text
);


ALTER TABLE public.plt1_p2 OWNER TO ashutoshpg;

--
-- Name: plt1_p3; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.plt1_p3 (
    a integer,
    b integer,
    c text
);


ALTER TABLE public.plt1_p3 OWNER TO ashutoshpg;

--
-- Name: plt2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.plt2 (
    a integer,
    b integer,
    c text
)
PARTITION BY LIST (c);


ALTER TABLE public.plt2 OWNER TO ashutoshpg;

--
-- Name: plt2_p1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.plt2_p1 (
    a integer,
    b integer,
    c text
);


ALTER TABLE public.plt2_p1 OWNER TO ashutoshpg;

--
-- Name: plt2_p2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.plt2_p2 (
    a integer,
    b integer,
    c text
);


ALTER TABLE public.plt2_p2 OWNER TO ashutoshpg;

--
-- Name: plt2_p3; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.plt2_p3 (
    a integer,
    b integer,
    c text
);


ALTER TABLE public.plt2_p3 OWNER TO ashutoshpg;

--
-- Name: point_table; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.point_table (
    a point,
    b integer
);


ALTER TABLE public.point_table OWNER TO ashutoshpg;

--
-- Name: point_tbl; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.point_tbl (
    f1 point
);


ALTER TABLE public.point_tbl OWNER TO ashutoshpg;

--
-- Name: polygon_tbl; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.polygon_tbl (
    f1 polygon
);


ALTER TABLE public.polygon_tbl OWNER TO ashutoshpg;

--
-- Name: prt1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt1 (
    a integer,
    b integer,
    c character varying
)
PARTITION BY RANGE (a);


ALTER TABLE public.prt1 OWNER TO ashutoshpg;

--
-- Name: prt1_e; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt1_e (
    a integer,
    b integer,
    c integer
)
PARTITION BY RANGE ((((a + b) / 2)));


ALTER TABLE public.prt1_e OWNER TO ashutoshpg;

--
-- Name: prt1_e_p1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt1_e_p1 (
    a integer,
    b integer,
    c integer
);


ALTER TABLE public.prt1_e_p1 OWNER TO ashutoshpg;

--
-- Name: prt1_e_p2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt1_e_p2 (
    a integer,
    b integer,
    c integer
);


ALTER TABLE public.prt1_e_p2 OWNER TO ashutoshpg;

--
-- Name: prt1_e_p3; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt1_e_p3 (
    a integer,
    b integer,
    c integer
);


ALTER TABLE public.prt1_e_p3 OWNER TO ashutoshpg;

--
-- Name: prt1_l; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt1_l (
    a integer,
    b integer,
    c character varying
)
PARTITION BY RANGE (a);


ALTER TABLE public.prt1_l OWNER TO ashutoshpg;

--
-- Name: prt1_l_p1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt1_l_p1 (
    a integer,
    b integer,
    c character varying
);


ALTER TABLE public.prt1_l_p1 OWNER TO ashutoshpg;

--
-- Name: prt1_l_p2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt1_l_p2 (
    a integer,
    b integer,
    c character varying
)
PARTITION BY LIST (c);


ALTER TABLE public.prt1_l_p2 OWNER TO ashutoshpg;

--
-- Name: prt1_l_p2_p1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt1_l_p2_p1 (
    a integer,
    b integer,
    c character varying
);


ALTER TABLE public.prt1_l_p2_p1 OWNER TO ashutoshpg;

--
-- Name: prt1_l_p2_p2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt1_l_p2_p2 (
    a integer,
    b integer,
    c character varying
);


ALTER TABLE public.prt1_l_p2_p2 OWNER TO ashutoshpg;

--
-- Name: prt1_l_p3; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt1_l_p3 (
    a integer,
    b integer,
    c character varying
)
PARTITION BY RANGE (b);


ALTER TABLE public.prt1_l_p3 OWNER TO ashutoshpg;

--
-- Name: prt1_l_p3_p1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt1_l_p3_p1 (
    a integer,
    b integer,
    c character varying
);


ALTER TABLE public.prt1_l_p3_p1 OWNER TO ashutoshpg;

--
-- Name: prt1_l_p3_p2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt1_l_p3_p2 (
    a integer,
    b integer,
    c character varying
);


ALTER TABLE public.prt1_l_p3_p2 OWNER TO ashutoshpg;

--
-- Name: prt1_m; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt1_m (
    a integer,
    b integer,
    c integer
)
PARTITION BY RANGE (a, (((a + b) / 2)));


ALTER TABLE public.prt1_m OWNER TO ashutoshpg;

--
-- Name: prt1_m_p1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt1_m_p1 (
    a integer,
    b integer,
    c integer
);


ALTER TABLE public.prt1_m_p1 OWNER TO ashutoshpg;

--
-- Name: prt1_m_p2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt1_m_p2 (
    a integer,
    b integer,
    c integer
);


ALTER TABLE public.prt1_m_p2 OWNER TO ashutoshpg;

--
-- Name: prt1_m_p3; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt1_m_p3 (
    a integer,
    b integer,
    c integer
);


ALTER TABLE public.prt1_m_p3 OWNER TO ashutoshpg;

--
-- Name: prt1_n; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt1_n (
    a integer,
    b integer,
    c character varying
)
PARTITION BY RANGE (c);


ALTER TABLE public.prt1_n OWNER TO ashutoshpg;

--
-- Name: prt1_n_p1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt1_n_p1 (
    a integer,
    b integer,
    c character varying
);


ALTER TABLE public.prt1_n_p1 OWNER TO ashutoshpg;

--
-- Name: prt1_n_p2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt1_n_p2 (
    a integer,
    b integer,
    c character varying
);


ALTER TABLE public.prt1_n_p2 OWNER TO ashutoshpg;

--
-- Name: prt1_p1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt1_p1 (
    a integer,
    b integer,
    c character varying
);


ALTER TABLE public.prt1_p1 OWNER TO ashutoshpg;

--
-- Name: prt1_p2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt1_p2 (
    a integer,
    b integer,
    c character varying
);


ALTER TABLE public.prt1_p2 OWNER TO ashutoshpg;

--
-- Name: prt1_p3; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt1_p3 (
    a integer,
    b integer,
    c character varying
);


ALTER TABLE public.prt1_p3 OWNER TO ashutoshpg;

--
-- Name: prt2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt2 (
    a integer,
    b integer,
    c character varying
)
PARTITION BY RANGE (b);


ALTER TABLE public.prt2 OWNER TO ashutoshpg;

--
-- Name: prt2_e; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt2_e (
    a integer,
    b integer,
    c integer
)
PARTITION BY RANGE ((((b + a) / 2)));


ALTER TABLE public.prt2_e OWNER TO ashutoshpg;

--
-- Name: prt2_e_p1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt2_e_p1 (
    a integer,
    b integer,
    c integer
);


ALTER TABLE public.prt2_e_p1 OWNER TO ashutoshpg;

--
-- Name: prt2_e_p2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt2_e_p2 (
    a integer,
    b integer,
    c integer
);


ALTER TABLE public.prt2_e_p2 OWNER TO ashutoshpg;

--
-- Name: prt2_e_p3; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt2_e_p3 (
    a integer,
    b integer,
    c integer
);


ALTER TABLE public.prt2_e_p3 OWNER TO ashutoshpg;

--
-- Name: prt2_l; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt2_l (
    a integer,
    b integer,
    c character varying
)
PARTITION BY RANGE (b);


ALTER TABLE public.prt2_l OWNER TO ashutoshpg;

--
-- Name: prt2_l_p1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt2_l_p1 (
    a integer,
    b integer,
    c character varying
);


ALTER TABLE public.prt2_l_p1 OWNER TO ashutoshpg;

--
-- Name: prt2_l_p2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt2_l_p2 (
    a integer,
    b integer,
    c character varying
)
PARTITION BY LIST (c);


ALTER TABLE public.prt2_l_p2 OWNER TO ashutoshpg;

--
-- Name: prt2_l_p2_p1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt2_l_p2_p1 (
    a integer,
    b integer,
    c character varying
);


ALTER TABLE public.prt2_l_p2_p1 OWNER TO ashutoshpg;

--
-- Name: prt2_l_p2_p2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt2_l_p2_p2 (
    a integer,
    b integer,
    c character varying
);


ALTER TABLE public.prt2_l_p2_p2 OWNER TO ashutoshpg;

--
-- Name: prt2_l_p3; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt2_l_p3 (
    a integer,
    b integer,
    c character varying
)
PARTITION BY RANGE (a);


ALTER TABLE public.prt2_l_p3 OWNER TO ashutoshpg;

--
-- Name: prt2_l_p3_p1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt2_l_p3_p1 (
    a integer,
    b integer,
    c character varying
);


ALTER TABLE public.prt2_l_p3_p1 OWNER TO ashutoshpg;

--
-- Name: prt2_l_p3_p2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt2_l_p3_p2 (
    a integer,
    b integer,
    c character varying
);


ALTER TABLE public.prt2_l_p3_p2 OWNER TO ashutoshpg;

--
-- Name: prt2_m; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt2_m (
    a integer,
    b integer,
    c integer
)
PARTITION BY RANGE ((((b + a) / 2)), b);


ALTER TABLE public.prt2_m OWNER TO ashutoshpg;

--
-- Name: prt2_m_p1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt2_m_p1 (
    a integer,
    b integer,
    c integer
);


ALTER TABLE public.prt2_m_p1 OWNER TO ashutoshpg;

--
-- Name: prt2_m_p2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt2_m_p2 (
    a integer,
    b integer,
    c integer
);


ALTER TABLE public.prt2_m_p2 OWNER TO ashutoshpg;

--
-- Name: prt2_m_p3; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt2_m_p3 (
    a integer,
    b integer,
    c integer
);


ALTER TABLE public.prt2_m_p3 OWNER TO ashutoshpg;

--
-- Name: prt2_n; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt2_n (
    a integer,
    b integer,
    c text
)
PARTITION BY LIST (c);


ALTER TABLE public.prt2_n OWNER TO ashutoshpg;

--
-- Name: prt2_n_p1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt2_n_p1 (
    a integer,
    b integer,
    c text
);


ALTER TABLE public.prt2_n_p1 OWNER TO ashutoshpg;

--
-- Name: prt2_n_p2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt2_n_p2 (
    a integer,
    b integer,
    c text
);


ALTER TABLE public.prt2_n_p2 OWNER TO ashutoshpg;

--
-- Name: prt2_p1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt2_p1 (
    a integer,
    b integer,
    c character varying
);


ALTER TABLE public.prt2_p1 OWNER TO ashutoshpg;

--
-- Name: prt2_p2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt2_p2 (
    a integer,
    b integer,
    c character varying
);


ALTER TABLE public.prt2_p2 OWNER TO ashutoshpg;

--
-- Name: prt2_p3; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt2_p3 (
    a integer,
    b integer,
    c character varying
);


ALTER TABLE public.prt2_p3 OWNER TO ashutoshpg;

--
-- Name: prt3_n; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt3_n (
    a integer,
    b integer,
    c text
)
PARTITION BY LIST (c);


ALTER TABLE public.prt3_n OWNER TO ashutoshpg;

--
-- Name: prt3_n_p1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt3_n_p1 (
    a integer,
    b integer,
    c text
);


ALTER TABLE public.prt3_n_p1 OWNER TO ashutoshpg;

--
-- Name: prt3_n_p2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt3_n_p2 (
    a integer,
    b integer,
    c text
);


ALTER TABLE public.prt3_n_p2 OWNER TO ashutoshpg;

--
-- Name: prt3_n_p3; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt3_n_p3 (
    a integer,
    b integer,
    c text
);


ALTER TABLE public.prt3_n_p3 OWNER TO ashutoshpg;

--
-- Name: prt4_n; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt4_n (
    a integer,
    b integer,
    c text
)
PARTITION BY RANGE (a);


ALTER TABLE public.prt4_n OWNER TO ashutoshpg;

--
-- Name: prt4_n_p1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt4_n_p1 (
    a integer,
    b integer,
    c text
);


ALTER TABLE public.prt4_n_p1 OWNER TO ashutoshpg;

--
-- Name: prt4_n_p2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt4_n_p2 (
    a integer,
    b integer,
    c text
);


ALTER TABLE public.prt4_n_p2 OWNER TO ashutoshpg;

--
-- Name: prt4_n_p3; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.prt4_n_p3 (
    a integer,
    b integer,
    c text
);


ALTER TABLE public.prt4_n_p3 OWNER TO ashutoshpg;

--
-- Name: pt_part1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.pt_part1 (
    a integer,
    b text
);


ALTER TABLE public.pt_part1 OWNER TO ashutoshpg;

--
-- Name: pt_part2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.pt_part2 (
    a integer,
    b text
);


ALTER TABLE public.pt_part2 OWNER TO ashutoshpg;

--
-- Name: quad_box_tbl; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.quad_box_tbl (
    id integer,
    b box
);


ALTER TABLE public.quad_box_tbl OWNER TO ashutoshpg;

--
-- Name: quad_box_tbl_ord_seq1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.quad_box_tbl_ord_seq1 (
    n bigint,
    dist double precision,
    id integer
);


ALTER TABLE public.quad_box_tbl_ord_seq1 OWNER TO ashutoshpg;

--
-- Name: quad_box_tbl_ord_seq2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.quad_box_tbl_ord_seq2 (
    n bigint,
    dist double precision,
    id integer
);


ALTER TABLE public.quad_box_tbl_ord_seq2 OWNER TO ashutoshpg;

--
-- Name: quad_point_tbl; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.quad_point_tbl (
    p point
);


ALTER TABLE public.quad_point_tbl OWNER TO ashutoshpg;

--
-- Name: quad_poly_tbl; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.quad_poly_tbl (
    id integer,
    p polygon
);


ALTER TABLE public.quad_poly_tbl OWNER TO ashutoshpg;

--
-- Name: query; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.query (
    expr text
);


ALTER TABLE public.query OWNER TO ashutoshpg;

--
-- Name: radix_text_tbl; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.radix_text_tbl (
    t text
);


ALTER TABLE public.radix_text_tbl OWNER TO ashutoshpg;

--
-- Name: rc_test; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.rc_test (
    a integer,
    b integer
);


ALTER TABLE public.rc_test OWNER TO ashutoshpg;

--
-- Name: real_city; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.real_city (
    pop integer,
    cname text,
    outline path
);


ALTER TABLE public.real_city OWNER TO ashutoshpg;

--
-- Name: regress_constr_partitioned; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.regress_constr_partitioned (
    a integer
)
PARTITION BY LIST (a);


ALTER TABLE public.regress_constr_partitioned OWNER TO ashutoshpg;

--
-- Name: regress_constr_partition1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.regress_constr_partition1 (
    a integer NOT NULL
);


ALTER TABLE public.regress_constr_partition1 OWNER TO ashutoshpg;

--
-- Name: reloptions_test; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.reloptions_test (
    s character varying
)
WITH (autovacuum_vacuum_cost_delay='24', fillfactor='40', toast.autovacuum_vacuum_cost_delay='23');


ALTER TABLE public.reloptions_test OWNER TO ashutoshpg;

--
-- Name: renamecolumn; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.renamecolumn (
    d integer,
    w integer
);


ALTER TABLE public.renamecolumn OWNER TO ashutoshpg;

--
-- Name: renamecolumnchild; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.renamecolumnchild (
    a integer
)
INHERITS (public.renamecolumn);


ALTER TABLE public.renamecolumnchild OWNER TO ashutoshpg;

--
-- Name: renamecolumnanother; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.renamecolumnanother (
    c integer
)
INHERITS (public.renamecolumnchild);


ALTER TABLE public.renamecolumnanother OWNER TO ashutoshpg;

--
-- Name: reservations; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.reservations (
    room_id integer NOT NULL,
    booked_during daterange
);


ALTER TABLE public.reservations OWNER TO ashutoshpg;

--
-- Name: rewritemetoo1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.rewritemetoo1 OF public.rewritetype;


ALTER TABLE public.rewritemetoo1 OWNER TO ashutoshpg;

--
-- Name: rewritemetoo2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.rewritemetoo2 OF public.rewritetype;


ALTER TABLE public.rewritemetoo2 OWNER TO ashutoshpg;

--
-- Name: rewritemetoo3; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.rewritemetoo3 (
    a public.rewritetype
);


ALTER TABLE public.rewritemetoo3 OWNER TO ashutoshpg;

--
-- Name: room; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.room (
    roomno character(8),
    comment text
);


ALTER TABLE public.room OWNER TO ashutoshpg;

--
-- Name: rtest_admin; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.rtest_admin (
    pname text,
    sysname text
);


ALTER TABLE public.rtest_admin OWNER TO ashutoshpg;

--
-- Name: rtest_comp; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.rtest_comp (
    part text,
    unit character(4),
    size double precision
);


ALTER TABLE public.rtest_comp OWNER TO ashutoshpg;

--
-- Name: rtest_emp; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.rtest_emp (
    ename character(20),
    salary numeric
);


ALTER TABLE public.rtest_emp OWNER TO ashutoshpg;

--
-- Name: rtest_emplog; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.rtest_emplog (
    ename character(20),
    who name,
    action character(10),
    newsal numeric,
    oldsal numeric
);


ALTER TABLE public.rtest_emplog OWNER TO ashutoshpg;

--
-- Name: rtest_empmass; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.rtest_empmass (
    ename character(20),
    salary numeric
);


ALTER TABLE public.rtest_empmass OWNER TO ashutoshpg;

--
-- Name: rtest_interface; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.rtest_interface (
    sysname text,
    ifname text
);


ALTER TABLE public.rtest_interface OWNER TO ashutoshpg;

--
-- Name: rtest_nothn1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.rtest_nothn1 (
    a integer,
    b text
);


ALTER TABLE public.rtest_nothn1 OWNER TO ashutoshpg;

--
-- Name: rtest_nothn2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.rtest_nothn2 (
    a integer,
    b text
);


ALTER TABLE public.rtest_nothn2 OWNER TO ashutoshpg;

--
-- Name: rtest_nothn3; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.rtest_nothn3 (
    a integer,
    b text
);


ALTER TABLE public.rtest_nothn3 OWNER TO ashutoshpg;

--
-- Name: rtest_nothn4; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.rtest_nothn4 (
    a integer,
    b text
);


ALTER TABLE public.rtest_nothn4 OWNER TO ashutoshpg;

--
-- Name: rtest_order1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.rtest_order1 (
    a integer
);


ALTER TABLE public.rtest_order1 OWNER TO ashutoshpg;

--
-- Name: rtest_order2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.rtest_order2 (
    a integer,
    b integer,
    c text
);


ALTER TABLE public.rtest_order2 OWNER TO ashutoshpg;

--
-- Name: rtest_person; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.rtest_person (
    pname text,
    pdesc text
);


ALTER TABLE public.rtest_person OWNER TO ashutoshpg;

--
-- Name: rtest_seq; Type: SEQUENCE; Schema: public; Owner: ashutoshpg
--

CREATE SEQUENCE public.rtest_seq
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1;


ALTER SEQUENCE public.rtest_seq OWNER TO ashutoshpg;

--
-- Name: rtest_system; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.rtest_system (
    sysname text,
    sysdesc text
);


ALTER TABLE public.rtest_system OWNER TO ashutoshpg;

--
-- Name: rtest_t1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.rtest_t1 (
    a integer,
    b integer
);


ALTER TABLE public.rtest_t1 OWNER TO ashutoshpg;

--
-- Name: rtest_t2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.rtest_t2 (
    a integer,
    b integer
);


ALTER TABLE public.rtest_t2 OWNER TO ashutoshpg;

--
-- Name: rtest_t3; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.rtest_t3 (
    a integer,
    b integer
);


ALTER TABLE public.rtest_t3 OWNER TO ashutoshpg;

--
-- Name: rtest_t4; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.rtest_t4 (
    a integer,
    b text
);


ALTER TABLE public.rtest_t4 OWNER TO ashutoshpg;

--
-- Name: rtest_t5; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.rtest_t5 (
    a integer,
    b text
);


ALTER TABLE public.rtest_t5 OWNER TO ashutoshpg;

--
-- Name: rtest_t6; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.rtest_t6 (
    a integer,
    b text
);


ALTER TABLE public.rtest_t6 OWNER TO ashutoshpg;

--
-- Name: rtest_t7; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.rtest_t7 (
    a integer,
    b text
);


ALTER TABLE public.rtest_t7 OWNER TO ashutoshpg;

--
-- Name: rtest_t8; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.rtest_t8 (
    a integer,
    b text
);


ALTER TABLE public.rtest_t8 OWNER TO ashutoshpg;

--
-- Name: rtest_t9; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.rtest_t9 (
    a integer,
    b text
);


ALTER TABLE public.rtest_t9 OWNER TO ashutoshpg;

--
-- Name: rtest_unitfact; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.rtest_unitfact (
    unit character(4),
    factor double precision
);


ALTER TABLE public.rtest_unitfact OWNER TO ashutoshpg;

--
-- Name: rtest_v1; Type: VIEW; Schema: public; Owner: ashutoshpg
--

CREATE VIEW public.rtest_v1 AS
 SELECT a,
    b
   FROM public.rtest_t1;


ALTER VIEW public.rtest_v1 OWNER TO ashutoshpg;

--
-- Name: rtest_vcomp; Type: VIEW; Schema: public; Owner: ashutoshpg
--

CREATE VIEW public.rtest_vcomp AS
 SELECT x.part,
    (x.size * y.factor) AS size_in_cm
   FROM public.rtest_comp x,
    public.rtest_unitfact y
  WHERE (x.unit = y.unit);


ALTER VIEW public.rtest_vcomp OWNER TO ashutoshpg;

--
-- Name: rtest_view1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.rtest_view1 (
    a integer,
    b text,
    v boolean
);


ALTER TABLE public.rtest_view1 OWNER TO ashutoshpg;

--
-- Name: rtest_view2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.rtest_view2 (
    a integer
);


ALTER TABLE public.rtest_view2 OWNER TO ashutoshpg;

--
-- Name: rtest_view3; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.rtest_view3 (
    a integer,
    b text
);


ALTER TABLE public.rtest_view3 OWNER TO ashutoshpg;

--
-- Name: rtest_view4; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.rtest_view4 (
    a integer,
    b text,
    c integer
);


ALTER TABLE public.rtest_view4 OWNER TO ashutoshpg;

--
-- Name: rtest_vview1; Type: VIEW; Schema: public; Owner: ashutoshpg
--

CREATE VIEW public.rtest_vview1 AS
 SELECT a,
    b
   FROM public.rtest_view1 x
  WHERE (0 < ( SELECT count(*) AS count
           FROM public.rtest_view2 y
          WHERE (y.a = x.a)));


ALTER VIEW public.rtest_vview1 OWNER TO ashutoshpg;

--
-- Name: rtest_vview2; Type: VIEW; Schema: public; Owner: ashutoshpg
--

CREATE VIEW public.rtest_vview2 AS
 SELECT a,
    b
   FROM public.rtest_view1
  WHERE v;


ALTER VIEW public.rtest_vview2 OWNER TO ashutoshpg;

--
-- Name: rtest_vview3; Type: VIEW; Schema: public; Owner: ashutoshpg
--

CREATE VIEW public.rtest_vview3 AS
 SELECT a,
    b
   FROM public.rtest_vview2 x
  WHERE (0 < ( SELECT count(*) AS count
           FROM public.rtest_view2 y
          WHERE (y.a = x.a)));


ALTER VIEW public.rtest_vview3 OWNER TO ashutoshpg;

--
-- Name: rtest_vview4; Type: VIEW; Schema: public; Owner: ashutoshpg
--

CREATE VIEW public.rtest_vview4 AS
 SELECT x.a,
    x.b,
    count(y.a) AS refcount
   FROM public.rtest_view1 x,
    public.rtest_view2 y
  WHERE (x.a = y.a)
  GROUP BY x.a, x.b;


ALTER VIEW public.rtest_vview4 OWNER TO ashutoshpg;

--
-- Name: rtest_vview5; Type: VIEW; Schema: public; Owner: ashutoshpg
--

CREATE VIEW public.rtest_vview5 AS
 SELECT a,
    b,
    public.rtest_viewfunc1(a) AS refcount
   FROM public.rtest_view1;


ALTER VIEW public.rtest_vview5 OWNER TO ashutoshpg;

--
-- Name: rule_and_refint_t1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.rule_and_refint_t1 (
    id1a integer NOT NULL,
    id1b integer NOT NULL
);


ALTER TABLE public.rule_and_refint_t1 OWNER TO ashutoshpg;

--
-- Name: rule_and_refint_t2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.rule_and_refint_t2 (
    id2a integer NOT NULL,
    id2c integer NOT NULL
);


ALTER TABLE public.rule_and_refint_t2 OWNER TO ashutoshpg;

--
-- Name: rule_and_refint_t3; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.rule_and_refint_t3 (
    id3a integer NOT NULL,
    id3b integer NOT NULL,
    id3c integer NOT NULL,
    data text
);


ALTER TABLE public.rule_and_refint_t3 OWNER TO ashutoshpg;

--
-- Name: rule_merge1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.rule_merge1 (
    a integer,
    b text
);


ALTER TABLE public.rule_merge1 OWNER TO ashutoshpg;

--
-- Name: rule_merge2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.rule_merge2 (
    a integer,
    b text
);


ALTER TABLE public.rule_merge2 OWNER TO ashutoshpg;

--
-- Name: rules_log; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.rules_log (
    f1 integer,
    f2 integer,
    tag text,
    id integer NOT NULL
);


ALTER TABLE public.rules_log OWNER TO ashutoshpg;

--
-- Name: rules_log_id_seq; Type: SEQUENCE; Schema: public; Owner: ashutoshpg
--

CREATE SEQUENCE public.rules_log_id_seq
    AS integer
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1;


ALTER SEQUENCE public.rules_log_id_seq OWNER TO ashutoshpg;

--
-- Name: rules_log_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: ashutoshpg
--

ALTER SEQUENCE public.rules_log_id_seq OWNED BY public.rules_log.id;


--
-- Name: rules_src; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.rules_src (
    f1 integer,
    f2 integer DEFAULT 0
);


ALTER TABLE public.rules_src OWNER TO ashutoshpg;

--
-- Name: ruletest_tbl; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.ruletest_tbl (
    a integer,
    b integer
);


ALTER TABLE public.ruletest_tbl OWNER TO ashutoshpg;

--
-- Name: ruletest_tbl2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.ruletest_tbl2 (
    a integer,
    b integer
);


ALTER TABLE public.ruletest_tbl2 OWNER TO ashutoshpg;

--
-- Name: sequence_test10; Type: SEQUENCE; Schema: public; Owner: ashutoshpg
--

CREATE SEQUENCE public.sequence_test10
    AS smallint
    START WITH 1
    INCREMENT BY 1
    MINVALUE -20000
    NO MAXVALUE
    CACHE 1;


ALTER SEQUENCE public.sequence_test10 OWNER TO ashutoshpg;

--
-- Name: sequence_test11; Type: SEQUENCE; Schema: public; Owner: ashutoshpg
--

CREATE SEQUENCE public.sequence_test11
    AS integer
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1;


ALTER SEQUENCE public.sequence_test11 OWNER TO ashutoshpg;

--
-- Name: sequence_test12; Type: SEQUENCE; Schema: public; Owner: ashutoshpg
--

CREATE SEQUENCE public.sequence_test12
    AS integer
    START WITH -1
    INCREMENT BY -1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1;


ALTER SEQUENCE public.sequence_test12 OWNER TO ashutoshpg;

--
-- Name: sequence_test13; Type: SEQUENCE; Schema: public; Owner: ashutoshpg
--

CREATE SEQUENCE public.sequence_test13
    AS integer
    START WITH -32768
    INCREMENT BY 1
    MINVALUE -2147483648
    NO MAXVALUE
    CACHE 1;


ALTER SEQUENCE public.sequence_test13 OWNER TO ashutoshpg;

--
-- Name: sequence_test14; Type: SEQUENCE; Schema: public; Owner: ashutoshpg
--

CREATE SEQUENCE public.sequence_test14
    AS integer
    START WITH 32767
    INCREMENT BY -1
    NO MINVALUE
    MAXVALUE 2147483647
    CACHE 1;


ALTER SEQUENCE public.sequence_test14 OWNER TO ashutoshpg;

--
-- Name: sequence_test2; Type: SEQUENCE; Schema: public; Owner: ashutoshpg
--

CREATE SEQUENCE public.sequence_test2
    START WITH 32
    INCREMENT BY 4
    MINVALUE 5
    MAXVALUE 36
    CACHE 1
    CYCLE;


ALTER SEQUENCE public.sequence_test2 OWNER TO ashutoshpg;

--
-- Name: sequence_test3; Type: SEQUENCE; Schema: public; Owner: ashutoshpg
--

CREATE SEQUENCE public.sequence_test3
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1;


ALTER SEQUENCE public.sequence_test3 OWNER TO ashutoshpg;

--
-- Name: sequence_test4; Type: SEQUENCE; Schema: public; Owner: ashutoshpg
--

CREATE SEQUENCE public.sequence_test4
    START WITH -1
    INCREMENT BY -1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1;


ALTER SEQUENCE public.sequence_test4 OWNER TO ashutoshpg;

--
-- Name: sequence_test5; Type: SEQUENCE; Schema: public; Owner: ashutoshpg
--

CREATE SEQUENCE public.sequence_test5
    AS smallint
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1;


ALTER SEQUENCE public.sequence_test5 OWNER TO ashutoshpg;

--
-- Name: sequence_test6; Type: SEQUENCE; Schema: public; Owner: ashutoshpg
--

CREATE SEQUENCE public.sequence_test6
    AS smallint
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1;


ALTER SEQUENCE public.sequence_test6 OWNER TO ashutoshpg;

--
-- Name: sequence_test7; Type: SEQUENCE; Schema: public; Owner: ashutoshpg
--

CREATE SEQUENCE public.sequence_test7
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1;


ALTER SEQUENCE public.sequence_test7 OWNER TO ashutoshpg;

--
-- Name: sequence_test8; Type: SEQUENCE; Schema: public; Owner: ashutoshpg
--

CREATE SEQUENCE public.sequence_test8
    AS smallint
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    MAXVALUE 20000
    CACHE 1;


ALTER SEQUENCE public.sequence_test8 OWNER TO ashutoshpg;

--
-- Name: sequence_test9; Type: SEQUENCE; Schema: public; Owner: ashutoshpg
--

CREATE SEQUENCE public.sequence_test9
    AS smallint
    START WITH -1
    INCREMENT BY -1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1;


ALTER SEQUENCE public.sequence_test9 OWNER TO ashutoshpg;

--
-- Name: shiftjis2004_inputs; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.shiftjis2004_inputs (
    inbytes bytea,
    description text
);


ALTER TABLE public.shiftjis2004_inputs OWNER TO ashutoshpg;

--
-- Name: shighway; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.shighway (
    surface text
)
INHERITS (public.road);


ALTER TABLE public.shighway OWNER TO ashutoshpg;

--
-- Name: shoe_data; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.shoe_data (
    shoename character(10),
    sh_avail integer,
    slcolor character(10),
    slminlen double precision,
    slmaxlen double precision,
    slunit character(8)
);


ALTER TABLE public.shoe_data OWNER TO ashutoshpg;

--
-- Name: unit; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.unit (
    un_name character(8),
    un_fact double precision
);


ALTER TABLE public.unit OWNER TO ashutoshpg;

--
-- Name: shoe; Type: VIEW; Schema: public; Owner: ashutoshpg
--

CREATE VIEW public.shoe AS
 SELECT sh.shoename,
    sh.sh_avail,
    sh.slcolor,
    sh.slminlen,
    (sh.slminlen * un.un_fact) AS slminlen_cm,
    sh.slmaxlen,
    (sh.slmaxlen * un.un_fact) AS slmaxlen_cm,
    sh.slunit
   FROM public.shoe_data sh,
    public.unit un
  WHERE (sh.slunit = un.un_name);


ALTER VIEW public.shoe OWNER TO ashutoshpg;

--
-- Name: shoelace_data; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.shoelace_data (
    sl_name character(10),
    sl_avail integer,
    sl_color character(10),
    sl_len double precision,
    sl_unit character(8)
);


ALTER TABLE public.shoelace_data OWNER TO ashutoshpg;

--
-- Name: shoelace; Type: VIEW; Schema: public; Owner: ashutoshpg
--

CREATE VIEW public.shoelace AS
 SELECT s.sl_name,
    s.sl_avail,
    s.sl_color,
    s.sl_len,
    s.sl_unit,
    (s.sl_len * u.un_fact) AS sl_len_cm
   FROM public.shoelace_data s,
    public.unit u
  WHERE (s.sl_unit = u.un_name);


ALTER VIEW public.shoelace OWNER TO ashutoshpg;

--
-- Name: shoe_ready; Type: VIEW; Schema: public; Owner: ashutoshpg
--

CREATE VIEW public.shoe_ready AS
 SELECT rsh.shoename,
    rsh.sh_avail,
    rsl.sl_name,
    rsl.sl_avail,
    int4smaller(rsh.sh_avail, rsl.sl_avail) AS total_avail
   FROM public.shoe rsh,
    public.shoelace rsl
  WHERE ((rsl.sl_color = rsh.slcolor) AND (rsl.sl_len_cm >= rsh.slminlen_cm) AND (rsl.sl_len_cm <= rsh.slmaxlen_cm));


ALTER VIEW public.shoe_ready OWNER TO ashutoshpg;

--
-- Name: shoelace_arrive; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.shoelace_arrive (
    arr_name character(10),
    arr_quant integer
);


ALTER TABLE public.shoelace_arrive OWNER TO ashutoshpg;

--
-- Name: shoelace_obsolete; Type: VIEW; Schema: public; Owner: ashutoshpg
--

CREATE VIEW public.shoelace_obsolete AS
 SELECT sl_name,
    sl_avail,
    sl_color,
    sl_len,
    sl_unit,
    sl_len_cm
   FROM public.shoelace
  WHERE (NOT (EXISTS ( SELECT shoe.shoename
           FROM public.shoe
          WHERE (shoe.slcolor = shoelace.sl_color))));


ALTER VIEW public.shoelace_obsolete OWNER TO ashutoshpg;

--
-- Name: shoelace_candelete; Type: VIEW; Schema: public; Owner: ashutoshpg
--

CREATE VIEW public.shoelace_candelete AS
 SELECT sl_name,
    sl_avail,
    sl_color,
    sl_len,
    sl_unit,
    sl_len_cm
   FROM public.shoelace_obsolete
  WHERE (sl_avail = 0);


ALTER VIEW public.shoelace_candelete OWNER TO ashutoshpg;

--
-- Name: shoelace_log; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.shoelace_log (
    sl_name character(10),
    sl_avail integer,
    log_who name,
    log_when timestamp without time zone
);


ALTER TABLE public.shoelace_log OWNER TO ashutoshpg;

--
-- Name: shoelace_ok; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.shoelace_ok (
    ok_name character(10),
    ok_quant integer
);


ALTER TABLE public.shoelace_ok OWNER TO ashutoshpg;

--
-- Name: skip_wal_skip_rewrite_index; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.skip_wal_skip_rewrite_index (
    c character varying(20) NOT NULL
);


ALTER TABLE public.skip_wal_skip_rewrite_index OWNER TO ashutoshpg;

--
-- Name: slow_emp4000; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.slow_emp4000 (
    home_base box
);


ALTER TABLE public.slow_emp4000 OWNER TO ashutoshpg;

--
-- Name: spgist_box_tbl; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.spgist_box_tbl (
    id integer NOT NULL,
    b box
);


ALTER TABLE public.spgist_box_tbl OWNER TO ashutoshpg;

--
-- Name: spgist_box_tbl_id_seq; Type: SEQUENCE; Schema: public; Owner: ashutoshpg
--

CREATE SEQUENCE public.spgist_box_tbl_id_seq
    AS integer
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1;


ALTER SEQUENCE public.spgist_box_tbl_id_seq OWNER TO ashutoshpg;

--
-- Name: spgist_box_tbl_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: ashutoshpg
--

ALTER SEQUENCE public.spgist_box_tbl_id_seq OWNED BY public.spgist_box_tbl.id;


--
-- Name: spgist_domain_tbl; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.spgist_domain_tbl (
    f1 public.spgist_text
);


ALTER TABLE public.spgist_domain_tbl OWNER TO ashutoshpg;

--
-- Name: spgist_point_tbl; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.spgist_point_tbl (
    id integer,
    p point
);


ALTER TABLE public.spgist_point_tbl OWNER TO ashutoshpg;

--
-- Name: spgist_text_tbl; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.spgist_text_tbl (
    id integer,
    t text
);


ALTER TABLE public.spgist_text_tbl OWNER TO ashutoshpg;

--
-- Name: spgist_unlogged_tbl; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE UNLOGGED TABLE public.spgist_unlogged_tbl (
    id integer NOT NULL,
    b box
);


ALTER TABLE public.spgist_unlogged_tbl OWNER TO ashutoshpg;

--
-- Name: spgist_unlogged_tbl_id_seq; Type: SEQUENCE; Schema: public; Owner: ashutoshpg
--

CREATE UNLOGGED SEQUENCE public.spgist_unlogged_tbl_id_seq
    AS integer
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1;


ALTER SEQUENCE public.spgist_unlogged_tbl_id_seq OWNER TO ashutoshpg;

--
-- Name: spgist_unlogged_tbl_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: ashutoshpg
--

ALTER SEQUENCE public.spgist_unlogged_tbl_id_seq OWNED BY public.spgist_unlogged_tbl.id;


--
-- Name: stats_test_tab1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.stats_test_tab1 (
    a integer
);


ALTER TABLE public.stats_test_tab1 OWNER TO ashutoshpg;

--
-- Name: street; Type: VIEW; Schema: public; Owner: ashutoshpg
--

CREATE VIEW public.street AS
 SELECT r.name,
    r.thepath,
    c.cname
   FROM ONLY public.road r,
    public.real_city c
  WHERE (c.outline ?# r.thepath);


ALTER VIEW public.street OWNER TO ashutoshpg;

--
-- Name: student; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.student (
    gpa double precision
)
INHERITS (public.person);


ALTER TABLE public.student OWNER TO ashutoshpg;

--
-- Name: stud_emp; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.stud_emp (
    percent integer
)
INHERITS (public.emp, public.student);


ALTER TABLE public.stud_emp OWNER TO ashutoshpg;

--
-- Name: subselect_tbl; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.subselect_tbl (
    f1 integer,
    f2 integer,
    f3 double precision
);


ALTER TABLE public.subselect_tbl OWNER TO ashutoshpg;

--
-- Name: sums_1_100; Type: VIEW; Schema: public; Owner: ashutoshpg
--

CREATE VIEW public.sums_1_100 AS
 WITH RECURSIVE t(n) AS (
         VALUES (1)
        UNION ALL
         SELECT (t_1.n + 1)
           FROM t t_1
          WHERE (t_1.n < 100)
        )
 SELECT sum(n) AS sum
   FROM t;


ALTER VIEW public.sums_1_100 OWNER TO ashutoshpg;

--
-- Name: system; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.system (
    name text,
    comment text
);


ALTER TABLE public.system OWNER TO ashutoshpg;

--
-- Name: tab_core_types; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.tab_core_types (
    point point,
    line line,
    lseg lseg,
    box box,
    openedpath path,
    closedpath path,
    polygon polygon,
    circle circle,
    date date,
    "time" time without time zone,
    "timestamp" timestamp without time zone,
    timetz time with time zone,
    timestamptz timestamp with time zone,
    "interval" interval,
    "json" json,
    jsonb jsonb,
    jsonpath jsonpath,
    inet inet,
    cidr cidr,
    macaddr8 macaddr8,
    macaddr macaddr,
    int2 smallint,
    int4 integer,
    int8 bigint,
    float4 real,
    float8 double precision,
    pi numeric,
    "char" "char",
    bpchar bpchar,
    "varchar" character varying,
    name name,
    text text,
    bool boolean,
    bytea bytea,
    "bit" bit(1),
    varbit bit varying,
    money money,
    refcursor refcursor,
    int2vector int2vector,
    oidvector oidvector,
    aclitem aclitem,
    tsvector tsvector,
    tsquery tsquery,
    uuid uuid,
    xid8 xid8,
    regclass regclass,
    type regtype,
    regrole regrole,
    oid oid,
    tid tid,
    xid xid,
    cid cid,
    txid_snapshot txid_snapshot,
    pg_snapshot pg_snapshot,
    pg_lsn pg_lsn,
    cardinal_number information_schema.cardinal_number,
    character_data information_schema.character_data,
    sql_identifier information_schema.sql_identifier,
    time_stamp information_schema.time_stamp,
    yes_or_no information_schema.yes_or_no,
    int4range int4range,
    int4multirange int4multirange,
    int8range int8range,
    int8multirange int8multirange,
    numrange numrange,
    nummultirange nummultirange,
    daterange daterange,
    datemultirange datemultirange,
    tsrange tsrange,
    tsmultirange tsmultirange,
    tstzrange tstzrange,
    tstzmultirange tstzmultirange
);


ALTER TABLE public.tab_core_types OWNER TO ashutoshpg;

--
-- Name: tableam_parted_heap2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.tableam_parted_heap2 (
    a text,
    b integer
)
PARTITION BY LIST (a);


ALTER TABLE public.tableam_parted_heap2 OWNER TO ashutoshpg;

--
-- Name: tableam_parted_a_heap2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.tableam_parted_a_heap2 (
    a text,
    b integer
);


ALTER TABLE public.tableam_parted_a_heap2 OWNER TO ashutoshpg;


--
-- Name: tableam_parted_b_heap2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.tableam_parted_b_heap2 (
    a text,
    b integer
);


ALTER TABLE public.tableam_parted_b_heap2 OWNER TO ashutoshpg;


--
-- Name: tableam_parted_c_heap2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.tableam_parted_c_heap2 (
    a text,
    b integer
);


ALTER TABLE public.tableam_parted_c_heap2 OWNER TO ashutoshpg;


--
-- Name: tableam_parted_d_heap2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.tableam_parted_d_heap2 (
    a text,
    b integer
);


ALTER TABLE public.tableam_parted_d_heap2 OWNER TO ashutoshpg;

--
-- Name: tableam_tbl_heap2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.tableam_tbl_heap2 (
    f1 integer
);


ALTER TABLE public.tableam_tbl_heap2 OWNER TO ashutoshpg;

--
-- Name: tableam_tblas_heap2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.tableam_tblas_heap2 (
    f1 integer
);


ALTER TABLE public.tableam_tblas_heap2 OWNER TO ashutoshpg;

--
-- Name: tableam_tblmv_heap2; Type: MATERIALIZED VIEW; Schema: public; Owner: ashutoshpg
--

CREATE MATERIALIZED VIEW public.tableam_tblmv_heap2 AS
 SELECT f1
   FROM public.tableam_tbl_heap2
  WITH NO DATA;


ALTER MATERIALIZED VIEW public.tableam_tblmv_heap2 OWNER TO ashutoshpg;

--
-- Name: target_parted; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.target_parted (
    a integer,
    b integer
)
PARTITION BY LIST (a);


ALTER TABLE public.target_parted OWNER TO ashutoshpg;


--
-- Name: tbl_include_box; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.tbl_include_box (
    c1 integer NOT NULL,
    c2 integer NOT NULL,
    c3 integer,
    c4 box
);


ALTER TABLE public.tbl_include_box OWNER TO ashutoshpg;

--
-- Name: tbl_include_box_pk; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.tbl_include_box_pk (
    c1 integer,
    c2 integer,
    c3 integer,
    c4 box
);


ALTER TABLE public.tbl_include_box_pk OWNER TO ashutoshpg;

--
-- Name: tbl_include_pk; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.tbl_include_pk (
    c1 integer NOT NULL,
    c2 integer NOT NULL,
    c3 integer,
    c4 box
);


ALTER TABLE public.tbl_include_pk OWNER TO ashutoshpg;

--
-- Name: tbl_include_reg; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.tbl_include_reg (
    c1 integer,
    c2 integer,
    c3 integer,
    c4 box
);


ALTER TABLE public.tbl_include_reg OWNER TO ashutoshpg;

--
-- Name: tbl_include_unique1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.tbl_include_unique1 (
    c1 integer,
    c2 integer,
    c3 integer,
    c4 box
);


ALTER TABLE public.tbl_include_unique1 OWNER TO ashutoshpg;

--
-- Name: tbl_include_unique2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.tbl_include_unique2 (
    c1 integer,
    c2 integer,
    c3 integer,
    c4 box
);


ALTER TABLE public.tbl_include_unique2 OWNER TO ashutoshpg;

--
-- Name: temporal_fk2_mltrng2mltrng; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.temporal_fk2_mltrng2mltrng (
    id int4range NOT NULL,
    valid_at datemultirange NOT NULL,
    parent_id1 int4range,
    parent_id2 int4range
);


ALTER TABLE public.temporal_fk2_mltrng2mltrng OWNER TO ashutoshpg;

--
-- Name: temporal_fk2_rng2rng; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.temporal_fk2_rng2rng (
    id int4range NOT NULL,
    valid_at daterange NOT NULL,
    parent_id1 int4range,
    parent_id2 int4range
);


ALTER TABLE public.temporal_fk2_rng2rng OWNER TO ashutoshpg;

--
-- Name: temporal_fk_mltrng2mltrng; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.temporal_fk_mltrng2mltrng (
    id int4range NOT NULL,
    valid_at datemultirange NOT NULL,
    parent_id int4range
);


ALTER TABLE public.temporal_fk_mltrng2mltrng OWNER TO ashutoshpg;

--
-- Name: temporal_fk_rng2rng; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.temporal_fk_rng2rng (
    id int4range NOT NULL,
    valid_at daterange NOT NULL,
    parent_id int4range
);


ALTER TABLE public.temporal_fk_rng2rng OWNER TO ashutoshpg;

--
-- Name: temporal_mltrng; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.temporal_mltrng (
    id int4range NOT NULL,
    valid_at datemultirange NOT NULL
);


ALTER TABLE public.temporal_mltrng OWNER TO ashutoshpg;

--
-- Name: temporal_mltrng2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.temporal_mltrng2 (
    id1 int4range NOT NULL,
    id2 int4range NOT NULL,
    valid_at datemultirange NOT NULL
);


ALTER TABLE public.temporal_mltrng2 OWNER TO ashutoshpg;

--
-- Name: temporal_rng; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.temporal_rng (
    id int4range NOT NULL,
    valid_at daterange NOT NULL
);


ALTER TABLE public.temporal_rng OWNER TO ashutoshpg;

--
-- Name: temporal_rng2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.temporal_rng2 (
    id1 int4range NOT NULL,
    id2 int4range NOT NULL,
    valid_at daterange NOT NULL
);


ALTER TABLE public.temporal_rng2 OWNER TO ashutoshpg;

--
-- Name: tenk1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.tenk1 (
    unique1 integer,
    unique2 integer,
    two integer,
    four integer,
    ten integer,
    twenty integer,
    hundred integer,
    thousand integer,
    twothousand integer,
    fivethous integer,
    tenthous integer,
    odd integer,
    even integer,
    stringu1 name,
    stringu2 name,
    string4 name
);


ALTER TABLE public.tenk1 OWNER TO ashutoshpg;

--
-- Name: tenk2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.tenk2 (
    unique1 integer,
    unique2 integer,
    two integer,
    four integer,
    ten integer,
    twenty integer,
    hundred integer,
    thousand integer,
    twothousand integer,
    fivethous integer,
    tenthous integer,
    odd integer,
    even integer,
    stringu1 name,
    stringu2 name,
    string4 name
);


ALTER TABLE public.tenk2 OWNER TO ashutoshpg;

--
-- Name: test_inh_check; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.test_inh_check (
    a numeric,
    b numeric,
    CONSTRAINT bmerged CHECK (((b)::double precision > (1)::double precision)),
    CONSTRAINT bnoinherit CHECK (((b)::double precision > (100)::double precision)) NO INHERIT,
    CONSTRAINT test_inh_check_a_check CHECK (((a)::double precision > (10.2)::double precision))
);


ALTER TABLE public.test_inh_check OWNER TO ashutoshpg;

--
-- Name: test_inh_check_child; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.test_inh_check_child (
    CONSTRAINT blocal CHECK (((b)::double precision < (1000)::double precision)),
    CONSTRAINT bmerged CHECK (((b)::double precision > (1)::double precision))
)
INHERITS (public.test_inh_check);


ALTER TABLE public.test_inh_check_child OWNER TO ashutoshpg;

--
-- Name: test_io_bulkwrite_strategy; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.test_io_bulkwrite_strategy (
    i integer
);


ALTER TABLE public.test_io_bulkwrite_strategy OWNER TO ashutoshpg;

--
-- Name: test_io_vac_strategy; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.test_io_vac_strategy (
    a integer,
    b integer
)
WITH (autovacuum_enabled='false');


ALTER TABLE public.test_io_vac_strategy OWNER TO ashutoshpg;

--
-- Name: test_is_json; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.test_is_json (
    js text
);


ALTER TABLE public.test_is_json OWNER TO ashutoshpg;

--
-- Name: test_range_excl; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.test_range_excl (
    room int4range,
    speaker int4range,
    during tsrange
);


ALTER TABLE public.test_range_excl OWNER TO ashutoshpg;

--
-- Name: test_range_gist; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.test_range_gist (
    ir int4range
);


ALTER TABLE public.test_range_gist OWNER TO ashutoshpg;

--
-- Name: test_range_spgist; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.test_range_spgist (
    ir int4range
);


ALTER TABLE public.test_range_spgist OWNER TO ashutoshpg;

--
-- Name: test_storage; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.test_storage (
    a text,
    c text,
    b integer DEFAULT (random())::integer
);
ALTER TABLE ONLY public.test_storage ALTER COLUMN a SET STORAGE EXTERNAL;
ALTER TABLE ONLY public.test_storage ALTER COLUMN c SET STORAGE PLAIN;


ALTER TABLE public.test_storage OWNER TO ashutoshpg;

--
-- Name: test_tablesample; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.test_tablesample (
    id integer,
    name text
)
WITH (fillfactor='10');


ALTER TABLE public.test_tablesample OWNER TO ashutoshpg;

--
-- Name: test_tablesample_v1; Type: VIEW; Schema: public; Owner: ashutoshpg
--

CREATE VIEW public.test_tablesample_v1 AS
 SELECT id
   FROM public.test_tablesample TABLESAMPLE system ((10 * 2)) REPEATABLE (2);


ALTER VIEW public.test_tablesample_v1 OWNER TO ashutoshpg;

--
-- Name: test_tablesample_v2; Type: VIEW; Schema: public; Owner: ashutoshpg
--

CREATE VIEW public.test_tablesample_v2 AS
 SELECT id
   FROM public.test_tablesample TABLESAMPLE system (99);


ALTER VIEW public.test_tablesample_v2 OWNER TO ashutoshpg;

--
-- Name: test_tbl3; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.test_tbl3 (
    c public.test_type3
);


ALTER TABLE public.test_tbl3 OWNER TO ashutoshpg;

--
-- Name: test_tsquery; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.test_tsquery (
    txtkeyword text,
    txtsample text,
    keyword tsquery,
    sample tsquery
);


ALTER TABLE public.test_tsquery OWNER TO ashutoshpg;

--
-- Name: test_tsvector; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.test_tsvector (
    t text,
    a tsvector
);


ALTER TABLE public.test_tsvector OWNER TO ashutoshpg;

--
-- Name: test_type_diff; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.test_type_diff (
    f1 integer,
    f2 bigint
);


ALTER TABLE public.test_type_diff OWNER TO ashutoshpg;

--
-- Name: test_type_diff2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.test_type_diff2 (
    int_two smallint,
    int_four bigint,
    int_eight bigint
);


ALTER TABLE public.test_type_diff2 OWNER TO ashutoshpg;

--
-- Name: test_type_diff2_c1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.test_type_diff2_c1 (
    int_four bigint,
    int_eight bigint,
    int_two smallint
)
INHERITS (public.test_type_diff2);


ALTER TABLE public.test_type_diff2_c1 OWNER TO ashutoshpg;

--
-- Name: test_type_diff2_c2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.test_type_diff2_c2 (
    int_eight bigint,
    int_two smallint,
    int_four bigint
)
INHERITS (public.test_type_diff2);


ALTER TABLE public.test_type_diff2_c2 OWNER TO ashutoshpg;

--
-- Name: test_type_diff2_c3; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.test_type_diff2_c3 (
    int_two smallint,
    int_four bigint,
    int_eight bigint
)
INHERITS (public.test_type_diff2);


ALTER TABLE public.test_type_diff2_c3 OWNER TO ashutoshpg;

--
-- Name: test_type_diff_c; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.test_type_diff_c (
    extra smallint
)
INHERITS (public.test_type_diff);


ALTER TABLE public.test_type_diff_c OWNER TO ashutoshpg;

--
-- Name: testjsonb; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.testjsonb (
    j jsonb
);


ALTER TABLE public.testjsonb OWNER TO ashutoshpg;

--
-- Name: text_tbl; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.text_tbl (
    f1 text
);


ALTER TABLE public.text_tbl OWNER TO ashutoshpg;

--
-- Name: textrange_test; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.textrange_test (
    tr public.textrange
);


ALTER TABLE public.textrange_test OWNER TO ashutoshpg;

--
-- Name: thethings; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.thethings (
    stuff public.things
);


ALTER TABLE public.thethings OWNER TO ashutoshpg;

--
-- Name: time_tbl; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.time_tbl (
    f1 time(2) without time zone
);


ALTER TABLE public.time_tbl OWNER TO ashutoshpg;

--
-- Name: timestamp_tbl; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.timestamp_tbl (
    d1 timestamp(2) without time zone
);


ALTER TABLE public.timestamp_tbl OWNER TO ashutoshpg;

--
-- Name: timestamptz_tbl; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.timestamptz_tbl (
    d1 timestamp(2) with time zone
);


ALTER TABLE public.timestamptz_tbl OWNER TO ashutoshpg;

--
-- Name: timetz_tbl; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.timetz_tbl (
    f1 time(2) with time zone
);


ALTER TABLE public.timetz_tbl OWNER TO ashutoshpg;

--
-- Name: toyemp; Type: VIEW; Schema: public; Owner: ashutoshpg
--

CREATE VIEW public.toyemp AS
 SELECT name,
    age,
    location,
    (12 * salary) AS annualsal
   FROM public.emp;


ALTER VIEW public.toyemp OWNER TO ashutoshpg;

--
-- Name: transition_table_base; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.transition_table_base (
    id integer NOT NULL,
    val text
);


ALTER TABLE public.transition_table_base OWNER TO ashutoshpg;

--
-- Name: transition_table_level1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.transition_table_level1 (
    level1_no integer NOT NULL,
    level1_node_name character varying(255)
);


ALTER TABLE public.transition_table_level1 OWNER TO ashutoshpg;

--
-- Name: transition_table_level1_level1_no_seq; Type: SEQUENCE; Schema: public; Owner: ashutoshpg
--

CREATE SEQUENCE public.transition_table_level1_level1_no_seq
    AS integer
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1;


ALTER SEQUENCE public.transition_table_level1_level1_no_seq OWNER TO ashutoshpg;

--
-- Name: transition_table_level1_level1_no_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: ashutoshpg
--

ALTER SEQUENCE public.transition_table_level1_level1_no_seq OWNED BY public.transition_table_level1.level1_no;


--
-- Name: transition_table_level2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.transition_table_level2 (
    level2_no integer NOT NULL,
    parent_no integer NOT NULL,
    level1_node_name character varying(255)
);


ALTER TABLE public.transition_table_level2 OWNER TO ashutoshpg;

--
-- Name: transition_table_level2_level2_no_seq; Type: SEQUENCE; Schema: public; Owner: ashutoshpg
--

CREATE SEQUENCE public.transition_table_level2_level2_no_seq
    AS integer
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1;


ALTER SEQUENCE public.transition_table_level2_level2_no_seq OWNER TO ashutoshpg;

--
-- Name: transition_table_level2_level2_no_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: ashutoshpg
--

ALTER SEQUENCE public.transition_table_level2_level2_no_seq OWNED BY public.transition_table_level2.level2_no;


--
-- Name: transition_table_status; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.transition_table_status (
    level integer NOT NULL,
    node_no integer NOT NULL,
    status integer
);


ALTER TABLE public.transition_table_status OWNER TO ashutoshpg;

--
-- Name: trigger_parted; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.trigger_parted (
    a integer NOT NULL
)
PARTITION BY LIST (a);


ALTER TABLE public.trigger_parted OWNER TO ashutoshpg;

--
-- Name: trigger_parted_p1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.trigger_parted_p1 (
    a integer CONSTRAINT trigger_parted_a_not_null NOT NULL
)
PARTITION BY LIST (a);


ALTER TABLE public.trigger_parted_p1 OWNER TO ashutoshpg;

--
-- Name: trigger_parted_p1_1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.trigger_parted_p1_1 (
    a integer CONSTRAINT trigger_parted_a_not_null NOT NULL
);


ALTER TABLE public.trigger_parted_p1_1 OWNER TO ashutoshpg;

--
-- Name: trigger_parted_p2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.trigger_parted_p2 (
    a integer CONSTRAINT trigger_parted_a_not_null NOT NULL
)
PARTITION BY LIST (a);


ALTER TABLE public.trigger_parted_p2 OWNER TO ashutoshpg;

--
-- Name: trigger_parted_p2_2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.trigger_parted_p2_2 (
    a integer CONSTRAINT trigger_parted_a_not_null NOT NULL
);


ALTER TABLE public.trigger_parted_p2_2 OWNER TO ashutoshpg;

--
-- Name: truncate_b; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.truncate_b (
    id integer NOT NULL
);


ALTER TABLE public.truncate_b OWNER TO ashutoshpg;

--
-- Name: truncate_b_id_seq; Type: SEQUENCE; Schema: public; Owner: ashutoshpg
--

ALTER TABLE public.truncate_b ALTER COLUMN id ADD GENERATED ALWAYS AS IDENTITY (
    SEQUENCE NAME public.truncate_b_id_seq
    START WITH 44
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1
);


--
-- Name: tt0; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.tt0 OF public.tt_t0 (
    x NOT NULL
);


ALTER TABLE public.tt0 OWNER TO ashutoshpg;

--
-- Name: tt1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.tt1 (
    x integer,
    y bigint
);


ALTER TABLE public.tt1 OWNER TO ashutoshpg;

--
-- Name: tt2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.tt2 (
    x integer,
    y numeric(9,2)
);


ALTER TABLE public.tt2 OWNER TO ashutoshpg;

--
-- Name: tt3; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.tt3 (
    y numeric(8,2),
    x integer
);


ALTER TABLE public.tt3 OWNER TO ashutoshpg;

--
-- Name: tt4; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.tt4 (
    x integer
);


ALTER TABLE public.tt4 OWNER TO ashutoshpg;

--
-- Name: tt5; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.tt5 (
    x integer,
    y numeric(8,2),
    z integer
);


ALTER TABLE public.tt5 OWNER TO ashutoshpg;

--
-- Name: tt6; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.tt6 (
)
INHERITS (public.tt0);


ALTER TABLE public.tt6 OWNER TO ashutoshpg;

--
-- Name: tt7; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.tt7 (
    x integer,
    y numeric(8,2)
);


ALTER TABLE public.tt7 OWNER TO ashutoshpg;

--
-- Name: undroppable_objs; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.undroppable_objs (
    object_type text,
    object_identity text
);


ALTER TABLE public.undroppable_objs OWNER TO ashutoshpg;

--
-- Name: utf8_inputs; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.utf8_inputs (
    inbytes bytea,
    description text
);


ALTER TABLE public.utf8_inputs OWNER TO ashutoshpg;

--
-- Name: utf8_verification_inputs; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.utf8_verification_inputs (
    inbytes bytea,
    description text NOT NULL
);


ALTER TABLE public.utf8_verification_inputs OWNER TO ashutoshpg;

--
-- Name: varchar_tbl; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.varchar_tbl (
    f1 character varying(4)
);


ALTER TABLE public.varchar_tbl OWNER TO ashutoshpg;

--
-- Name: view_base_table; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.view_base_table (
    key integer NOT NULL,
    data character varying(20)
);


ALTER TABLE public.view_base_table OWNER TO ashutoshpg;

--
-- Name: wslot; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.wslot (
    slotname character(20),
    roomno character(8),
    slotlink character(20),
    backlink character(20)
);


ALTER TABLE public.wslot OWNER TO ashutoshpg;

--
-- Name: xacttest; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.xacttest (
    a smallint,
    b real
);


ALTER TABLE public.xacttest OWNER TO ashutoshpg;

--
-- Name: xmldata; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.xmldata (
    data xml
);


ALTER TABLE public.xmldata OWNER TO ashutoshpg;

--
-- Name: xmltableview1; Type: VIEW; Schema: public; Owner: ashutoshpg
--

CREATE VIEW public.xmltableview1 AS
 SELECT "xmltable".id,
    "xmltable"._id,
    "xmltable".country_name,
    "xmltable".country_id,
    "xmltable".region_id,
    "xmltable".size,
    "xmltable".unit,
    "xmltable".premier_name
   FROM ( SELECT xmldata.data
           FROM public.xmldata) x,
    LATERAL XMLTABLE(('/ROWS/ROW'::text) PASSING (x.data) COLUMNS id integer PATH ('@id'::text), _id FOR ORDINALITY, country_name text PATH ('COUNTRY_NAME/text()'::text) NOT NULL, country_id text PATH ('COUNTRY_ID'::text), region_id integer PATH ('REGION_ID'::text), size double precision PATH ('SIZE'::text), unit text PATH ('SIZE/@unit'::text), premier_name text DEFAULT ('not specified'::text) PATH ('PREMIER_NAME'::text));


ALTER VIEW public.xmltableview1 OWNER TO ashutoshpg;

--
-- Name: xmltableview2; Type: VIEW; Schema: public; Owner: ashutoshpg
--

CREATE VIEW public.xmltableview2 AS
 SELECT a
   FROM XMLTABLE(XMLNAMESPACES ('http://x.y'::text AS zz), ('/zz:rows/zz:row'::text) PASSING ('<rows xmlns="http://x.y"><row><a>10</a></row></rows>'::xml) COLUMNS a integer PATH ('zz:a'::text));


ALTER VIEW public.xmltableview2 OWNER TO ashutoshpg;

--
-- Name: xmltest; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.xmltest (
    id integer,
    data xml
);


ALTER TABLE public.xmltest OWNER TO ashutoshpg;

--
-- Name: xmltest2; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.xmltest2 (
    x xml,
    _path text
);


ALTER TABLE public.xmltest2 OWNER TO ashutoshpg;

--
-- Name: xmlview1; Type: VIEW; Schema: public; Owner: ashutoshpg
--

CREATE VIEW public.xmlview1 AS
 SELECT xmlcomment('test'::text) AS xmlcomment;


ALTER VIEW public.xmlview1 OWNER TO ashutoshpg;

--
-- Name: xmlview2; Type: VIEW; Schema: public; Owner: ashutoshpg
--

CREATE VIEW public.xmlview2 AS
 SELECT XMLCONCAT('hello'::xml, 'you'::xml) AS "xmlconcat";


ALTER VIEW public.xmlview2 OWNER TO ashutoshpg;

--
-- Name: xmlview3; Type: VIEW; Schema: public; Owner: ashutoshpg
--

CREATE VIEW public.xmlview3 AS
 SELECT XMLELEMENT(NAME element, XMLATTRIBUTES(1 AS ":one:", 'deuce' AS two), 'content&') AS "xmlelement";


ALTER VIEW public.xmlview3 OWNER TO ashutoshpg;

--
-- Name: xmlview4; Type: VIEW; Schema: public; Owner: ashutoshpg
--

CREATE VIEW public.xmlview4 AS
 SELECT XMLELEMENT(NAME employee, XMLFOREST(name AS name, age AS age, salary AS pay)) AS "xmlelement"
   FROM public.emp;


ALTER VIEW public.xmlview4 OWNER TO ashutoshpg;

--
-- Name: xmlview5; Type: VIEW; Schema: public; Owner: ashutoshpg
--

CREATE VIEW public.xmlview5 AS
 SELECT XMLPARSE(CONTENT '<abc>x</abc>'::text STRIP WHITESPACE) AS "xmlparse";


ALTER VIEW public.xmlview5 OWNER TO ashutoshpg;

--
-- Name: xmlview6; Type: VIEW; Schema: public; Owner: ashutoshpg
--

CREATE VIEW public.xmlview6 AS
 SELECT XMLPI(NAME foo, 'bar'::text) AS "xmlpi";


ALTER VIEW public.xmlview6 OWNER TO ashutoshpg;

--
-- Name: xmlview7; Type: VIEW; Schema: public; Owner: ashutoshpg
--

CREATE VIEW public.xmlview7 AS
 SELECT XMLROOT('<foo/>'::xml, VERSION NO VALUE, STANDALONE YES) AS "xmlroot";


ALTER VIEW public.xmlview7 OWNER TO ashutoshpg;

--
-- Name: xmlview8; Type: VIEW; Schema: public; Owner: ashutoshpg
--

CREATE VIEW public.xmlview8 AS
 SELECT (XMLSERIALIZE(CONTENT 'good'::xml AS character(10)))::character(10) AS "xmlserialize";


ALTER VIEW public.xmlview8 OWNER TO ashutoshpg;

--
-- Name: xmlview9; Type: VIEW; Schema: public; Owner: ashutoshpg
--

CREATE VIEW public.xmlview9 AS
 SELECT XMLSERIALIZE(CONTENT 'good'::xml AS text) AS "xmlserialize";


ALTER VIEW public.xmlview9 OWNER TO ashutoshpg;

--
-- Name: xy_1; Type: TABLE; Schema: public; Owner: ashutoshpg
--

CREATE TABLE public.xy_1 (
    x integer,
    y integer
);


ALTER TABLE public.xy_1 OWNER TO ashutoshpg;

--
-- Name: pk; Type: TABLE; Schema: regress_indexing; Owner: ashutoshpg
--

CREATE TABLE regress_indexing.pk (
    a integer NOT NULL
)
PARTITION BY RANGE (a);


ALTER TABLE regress_indexing.pk OWNER TO ashutoshpg;

--
-- Name: pk1; Type: TABLE; Schema: regress_indexing; Owner: ashutoshpg
--

CREATE TABLE regress_indexing.pk1 (
    a integer CONSTRAINT pk_a_not_null NOT NULL
);


ALTER TABLE regress_indexing.pk1 OWNER TO ashutoshpg;

--
-- Name: pk2; Type: TABLE; Schema: regress_indexing; Owner: ashutoshpg
--

CREATE TABLE regress_indexing.pk2 (
    a integer NOT NULL
);


ALTER TABLE regress_indexing.pk2 OWNER TO ashutoshpg;

--
-- Name: pk3; Type: TABLE; Schema: regress_indexing; Owner: ashutoshpg
--

CREATE TABLE regress_indexing.pk3 (
    a integer CONSTRAINT pk_a_not_null NOT NULL
);


ALTER TABLE regress_indexing.pk3 OWNER TO ashutoshpg;

--
-- Name: pk4; Type: TABLE; Schema: regress_indexing; Owner: ashutoshpg
--

CREATE TABLE regress_indexing.pk4 (
    a integer CONSTRAINT pk_a_not_null NOT NULL
);


ALTER TABLE regress_indexing.pk4 OWNER TO ashutoshpg;

--
-- Name: pk5; Type: TABLE; Schema: regress_indexing; Owner: ashutoshpg
--

CREATE TABLE regress_indexing.pk5 (
    a integer CONSTRAINT pk_a_not_null NOT NULL
)
PARTITION BY RANGE (a);


ALTER TABLE regress_indexing.pk5 OWNER TO ashutoshpg;

--
-- Name: pk51; Type: TABLE; Schema: regress_indexing; Owner: ashutoshpg
--

CREATE TABLE regress_indexing.pk51 (
    a integer CONSTRAINT pk_a_not_null NOT NULL
);


ALTER TABLE regress_indexing.pk51 OWNER TO ashutoshpg;

--
-- Name: pk52; Type: TABLE; Schema: regress_indexing; Owner: ashutoshpg
--

CREATE TABLE regress_indexing.pk52 (
    a integer CONSTRAINT pk_a_not_null NOT NULL
);


ALTER TABLE regress_indexing.pk52 OWNER TO ashutoshpg;

--
-- Name: rls_tbl; Type: TABLE; Schema: regress_rls_schema; Owner: ashutoshpg
--

CREATE TABLE regress_rls_schema.rls_tbl (
    c1 integer
);


ALTER TABLE regress_rls_schema.rls_tbl OWNER TO ashutoshpg;

--
-- Name: rls_tbl_force; Type: TABLE; Schema: regress_rls_schema; Owner: ashutoshpg
--

CREATE TABLE regress_rls_schema.rls_tbl_force (
    c1 integer
);

ALTER TABLE ONLY regress_rls_schema.rls_tbl_force FORCE ROW LEVEL SECURITY;


ALTER TABLE regress_rls_schema.rls_tbl_force OWNER TO ashutoshpg;

--
-- Name: test1; Type: TABLE; Schema: testxmlschema; Owner: ashutoshpg
--

CREATE TABLE testxmlschema.test1 (
    a integer,
    b text
);


ALTER TABLE testxmlschema.test1 OWNER TO ashutoshpg;

--
-- Name: test2; Type: TABLE; Schema: testxmlschema; Owner: ashutoshpg
--

CREATE TABLE testxmlschema.test2 (
    z integer,
    y character varying(500),
    x character(6),
    w numeric(9,2),
    v smallint,
    u bigint,
    t real,
    s time without time zone,
    stz time with time zone,
    r timestamp without time zone,
    rtz timestamp with time zone,
    q date,
    p xml,
    o public.testxmldomain,
    n boolean,
    m bytea
);


ALTER TABLE testxmlschema.test2 OWNER TO ashutoshpg;

--
-- Name: test3; Type: TABLE; Schema: testxmlschema; Owner: ashutoshpg
--

CREATE TABLE testxmlschema.test3 (
    c1 boolean,
    c2 public.testboolxmldomain,
    c3 date,
    c4 public.testdatexmldomain
);


ALTER TABLE testxmlschema.test3 OWNER TO ashutoshpg;

--
-- Name: fk1; Type: TABLE ATTACH; Schema: fkpart3; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart3.fk ATTACH PARTITION fkpart3.fk1 FOR VALUES FROM (0) TO (750);


--
-- Name: fk2; Type: TABLE ATTACH; Schema: fkpart3; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart3.fk ATTACH PARTITION fkpart3.fk2 FOR VALUES FROM (750) TO (3500);


--
-- Name: fk3; Type: TABLE ATTACH; Schema: fkpart3; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart3.fk ATTACH PARTITION fkpart3.fk3 FOR VALUES FROM (3500) TO (5000);


--
-- Name: pk1; Type: TABLE ATTACH; Schema: fkpart3; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart3.pk ATTACH PARTITION fkpart3.pk1 FOR VALUES FROM (0) TO (1000);


--
-- Name: pk2; Type: TABLE ATTACH; Schema: fkpart3; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart3.pk ATTACH PARTITION fkpart3.pk2 FOR VALUES FROM (1000) TO (2000);


--
-- Name: pk3; Type: TABLE ATTACH; Schema: fkpart3; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart3.pk ATTACH PARTITION fkpart3.pk3 FOR VALUES FROM (2000) TO (3000);


--
-- Name: pk4; Type: TABLE ATTACH; Schema: fkpart3; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart3.pk ATTACH PARTITION fkpart3.pk4 FOR VALUES FROM (3000) TO (4000);


--
-- Name: pk5; Type: TABLE ATTACH; Schema: fkpart3; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart3.pk ATTACH PARTITION fkpart3.pk5 FOR VALUES FROM (4000) TO (5000);


--
-- Name: pk51; Type: TABLE ATTACH; Schema: fkpart3; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart3.pk5 ATTACH PARTITION fkpart3.pk51 FOR VALUES FROM (4000) TO (4500);


--
-- Name: pk52; Type: TABLE ATTACH; Schema: fkpart3; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart3.pk5 ATTACH PARTITION fkpart3.pk52 FOR VALUES FROM (4500) TO (5000);


--
-- Name: droppk1; Type: TABLE ATTACH; Schema: fkpart4; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart4.droppk ATTACH PARTITION fkpart4.droppk1 FOR VALUES FROM (0) TO (1000);


--
-- Name: droppk2; Type: TABLE ATTACH; Schema: fkpart4; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart4.droppk ATTACH PARTITION fkpart4.droppk2 FOR VALUES FROM (1000) TO (2000);


--
-- Name: droppk2_d; Type: TABLE ATTACH; Schema: fkpart4; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart4.droppk2 ATTACH PARTITION fkpart4.droppk2_d DEFAULT;


--
-- Name: droppk_d; Type: TABLE ATTACH; Schema: fkpart4; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart4.droppk ATTACH PARTITION fkpart4.droppk_d DEFAULT;


--
-- Name: fk1; Type: TABLE ATTACH; Schema: fkpart5; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart5.fk ATTACH PARTITION fkpart5.fk1 FOR VALUES IN (1);


--
-- Name: fk11; Type: TABLE ATTACH; Schema: fkpart5; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart5.fk1 ATTACH PARTITION fkpart5.fk11 FOR VALUES IN (1);


--
-- Name: fk2; Type: TABLE ATTACH; Schema: fkpart5; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart5.fk ATTACH PARTITION fkpart5.fk2 FOR VALUES IN (2);


--
-- Name: fk3; Type: TABLE ATTACH; Schema: fkpart5; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart5.fk ATTACH PARTITION fkpart5.fk3 FOR VALUES IN (3);


--
-- Name: pk1; Type: TABLE ATTACH; Schema: fkpart5; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart5.pk ATTACH PARTITION fkpart5.pk1 FOR VALUES IN (1);


--
-- Name: pk11; Type: TABLE ATTACH; Schema: fkpart5; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart5.pk1 ATTACH PARTITION fkpart5.pk11 FOR VALUES IN (1);


--
-- Name: pk2; Type: TABLE ATTACH; Schema: fkpart5; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart5.pk ATTACH PARTITION fkpart5.pk2 FOR VALUES IN (2);


--
-- Name: pk3; Type: TABLE ATTACH; Schema: fkpart5; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart5.pk ATTACH PARTITION fkpart5.pk3 FOR VALUES IN (31, 32);


--
-- Name: pk31; Type: TABLE ATTACH; Schema: fkpart5; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart5.pk3 ATTACH PARTITION fkpart5.pk31 FOR VALUES IN (31);


--
-- Name: pk32; Type: TABLE ATTACH; Schema: fkpart5; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart5.pk3 ATTACH PARTITION fkpart5.pk32 FOR VALUES IN (32);


--
-- Name: pk1; Type: TABLE ATTACH; Schema: fkpart6; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart6.pk ATTACH PARTITION fkpart6.pk1 FOR VALUES FROM (1) TO (100);


--
-- Name: pk11; Type: TABLE ATTACH; Schema: fkpart6; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart6.pk1 ATTACH PARTITION fkpart6.pk11 FOR VALUES FROM (1) TO (50);


--
-- Name: pk12; Type: TABLE ATTACH; Schema: fkpart6; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart6.pk1 ATTACH PARTITION fkpart6.pk12 FOR VALUES FROM (50) TO (100);


--
-- Name: gtest_child; Type: TABLE ATTACH; Schema: generated_stored_tests; Owner: ashutoshpg
--

ALTER TABLE ONLY generated_stored_tests.gtest_parent ATTACH PARTITION generated_stored_tests.gtest_child FOR VALUES FROM ('2016-07-01') TO ('2016-08-01');


--
-- Name: gtest_child2; Type: TABLE ATTACH; Schema: generated_stored_tests; Owner: ashutoshpg
--

ALTER TABLE ONLY generated_stored_tests.gtest_parent ATTACH PARTITION generated_stored_tests.gtest_child2 FOR VALUES FROM ('2016-08-01') TO ('2016-09-01');


--
-- Name: gtest_child3; Type: TABLE ATTACH; Schema: generated_stored_tests; Owner: ashutoshpg
--

ALTER TABLE ONLY generated_stored_tests.gtest_parent ATTACH PARTITION generated_stored_tests.gtest_child3 FOR VALUES FROM ('2016-09-01') TO ('2016-10-01');


--
-- Name: alpha_neg; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.alpha ATTACH PARTITION public.alpha_neg FOR VALUES FROM ('-Infinity') TO ('0');


--
-- Name: alpha_neg_p1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.alpha_neg ATTACH PARTITION public.alpha_neg_p1 FOR VALUES FROM (100) TO (200);


--
-- Name: alpha_neg_p2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.alpha_neg ATTACH PARTITION public.alpha_neg_p2 FOR VALUES FROM (200) TO (300);


--
-- Name: alpha_neg_p3; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.alpha_neg ATTACH PARTITION public.alpha_neg_p3 FOR VALUES FROM (300) TO (400);


--
-- Name: alpha_pos; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.alpha ATTACH PARTITION public.alpha_pos FOR VALUES FROM ('0') TO ('10');


--
-- Name: alpha_pos_p1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.alpha_pos ATTACH PARTITION public.alpha_pos_p1 FOR VALUES IN ('0001', '0003');


--
-- Name: alpha_pos_p2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.alpha_pos ATTACH PARTITION public.alpha_pos_p2 FOR VALUES IN ('0004', '0006');


--
-- Name: alpha_pos_p3; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.alpha_pos ATTACH PARTITION public.alpha_pos_p3 FOR VALUES IN ('0008', '0009');


--
-- Name: attach_parted_part1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.attach_parted ATTACH PARTITION public.attach_parted_part1 FOR VALUES IN (1);


--
-- Name: bar2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.bar1 ATTACH PARTITION public.bar2 DEFAULT;


--
-- Name: beta_neg; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.beta ATTACH PARTITION public.beta_neg FOR VALUES FROM ('-10') TO ('0');


--
-- Name: beta_neg_p1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.beta_neg ATTACH PARTITION public.beta_neg_p1 FOR VALUES FROM (100) TO (150);


--
-- Name: beta_neg_p2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.beta_neg ATTACH PARTITION public.beta_neg_p2 FOR VALUES FROM (200) TO (300);


--
-- Name: beta_neg_p3; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.beta_neg ATTACH PARTITION public.beta_neg_p3 FOR VALUES FROM (350) TO (500);


--
-- Name: beta_pos; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.beta ATTACH PARTITION public.beta_pos FOR VALUES FROM ('0') TO ('Infinity');


--
-- Name: beta_pos_p1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.beta_pos ATTACH PARTITION public.beta_pos_p1 FOR VALUES IN ('0002', '0003');


--
-- Name: beta_pos_p2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.beta_pos ATTACH PARTITION public.beta_pos_p2 FOR VALUES IN ('0004', '0006');


--
-- Name: beta_pos_p3; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.beta_pos ATTACH PARTITION public.beta_pos_p3 FOR VALUES IN ('0007', '0009');


--
-- Name: cmpart1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.cmpart ATTACH PARTITION public.cmpart1 FOR VALUES WITH (modulus 2, remainder 0);


--
-- Name: cmpart2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.cmpart ATTACH PARTITION public.cmpart2 FOR VALUES WITH (modulus 2, remainder 1);


--
-- Name: covidxpart1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.covidxpart ATTACH PARTITION public.covidxpart1 FOR VALUES IN (1);


--
-- Name: covidxpart2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.covidxpart ATTACH PARTITION public.covidxpart2 FOR VALUES IN (2);


--
-- Name: covidxpart3; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.covidxpart ATTACH PARTITION public.covidxpart3 FOR VALUES IN (3);


--
-- Name: covidxpart4; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.covidxpart ATTACH PARTITION public.covidxpart4 FOR VALUES IN (4);


--
-- Name: fk_partitioned_fk_1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.fk_partitioned_fk ATTACH PARTITION public.fk_partitioned_fk_1 FOR VALUES IN (NULL, 500, 501, 502);


--
-- Name: fk_partitioned_fk_2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.fk_partitioned_fk ATTACH PARTITION public.fk_partitioned_fk_2 FOR VALUES IN (1600);


--
-- Name: fk_partitioned_fk_2_1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.fk_partitioned_fk_2 ATTACH PARTITION public.fk_partitioned_fk_2_1 FOR VALUES FROM (0) TO (1000);


--
-- Name: fk_partitioned_fk_2_2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.fk_partitioned_fk_2 ATTACH PARTITION public.fk_partitioned_fk_2_2 FOR VALUES FROM (1000) TO (2000);


--
-- Name: fk_partitioned_fk_3; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.fk_partitioned_fk ATTACH PARTITION public.fk_partitioned_fk_3 FOR VALUES IN (2500, 2501, 2502, 2503);


--
-- Name: fk_partitioned_fk_4; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.fk_partitioned_fk ATTACH PARTITION public.fk_partitioned_fk_4 FOR VALUES IN (3500, 3502);


--
-- Name: fk_partitioned_fk_4_1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.fk_partitioned_fk_4 ATTACH PARTITION public.fk_partitioned_fk_4_1 FOR VALUES FROM (1, 1) TO (100, 100);


--
-- Name: fk_partitioned_fk_4_2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.fk_partitioned_fk_4 ATTACH PARTITION public.fk_partitioned_fk_4_2 FOR VALUES FROM (100, 100) TO (1000, 1000);


--
-- Name: fk_partitioned_fk_5; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.fk_partitioned_fk ATTACH PARTITION public.fk_partitioned_fk_5 FOR VALUES IN (4500);


--
-- Name: fk_partitioned_fk_5_1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.fk_partitioned_fk_5 ATTACH PARTITION public.fk_partitioned_fk_5_1 FOR VALUES FROM (0) TO (10);


--
-- Name: idxpart1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.idxpart ATTACH PARTITION public.idxpart1 FOR VALUES FROM (0) TO (100);


--
-- Name: idxpart2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.idxpart ATTACH PARTITION public.idxpart2 FOR VALUES FROM (100) TO (1000);


--
-- Name: idxpart21; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.idxpart2 ATTACH PARTITION public.idxpart21 FOR VALUES FROM (100) TO (200);


--
-- Name: idxpart22; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.idxpart2 ATTACH PARTITION public.idxpart22 FOR VALUES FROM (200) TO (300);


--
-- Name: idxpart3; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.idxpart ATTACH PARTITION public.idxpart3 FOR VALUES FROM (1000) TO (2000);


--
-- Name: idxpart31; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.idxpart3 ATTACH PARTITION public.idxpart31 FOR VALUES FROM (1000) TO (1200);


--
-- Name: idxpart32; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.idxpart3 ATTACH PARTITION public.idxpart32 FOR VALUES FROM (1200) TO (1400);


--
-- Name: idxpart_another_1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.idxpart_another ATTACH PARTITION public.idxpart_another_1 FOR VALUES FROM (0) TO (100);


--
-- Name: mlparted1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.mlparted ATTACH PARTITION public.mlparted1 FOR VALUES FROM (1, 2) TO (1, 10);


--
-- Name: mlparted11; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.mlparted1 ATTACH PARTITION public.mlparted11 FOR VALUES FROM (2) TO (5);


--
-- Name: mlparted12; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.mlparted1 ATTACH PARTITION public.mlparted12 FOR VALUES FROM (5) TO (10);


--
-- Name: mlparted2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.mlparted ATTACH PARTITION public.mlparted2 FOR VALUES FROM (1, 10) TO (1, 20);


--
-- Name: mlparted3; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.mlparted ATTACH PARTITION public.mlparted3 FOR VALUES FROM (1, 20) TO (1, 30);


--
-- Name: mlparted4; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.mlparted ATTACH PARTITION public.mlparted4 FOR VALUES FROM (1, 30) TO (1, 40);


--
-- Name: mlparted_def; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.mlparted ATTACH PARTITION public.mlparted_def DEFAULT;


--
-- Name: mlparted_def1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.mlparted_def ATTACH PARTITION public.mlparted_def1 FOR VALUES FROM (40) TO (50);


--
-- Name: mlparted_def2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.mlparted_def ATTACH PARTITION public.mlparted_def2 FOR VALUES FROM (50) TO (60);


--
-- Name: mlparted_defd; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.mlparted_def ATTACH PARTITION public.mlparted_defd DEFAULT;


--
-- Name: notnull_tbl6_1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.notnull_tbl6 ATTACH PARTITION public.notnull_tbl6_1 FOR VALUES IN (1);


--
-- Name: pagg_tab1_p1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.pagg_tab1 ATTACH PARTITION public.pagg_tab1_p1 FOR VALUES FROM (0) TO (10);


--
-- Name: pagg_tab1_p2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.pagg_tab1 ATTACH PARTITION public.pagg_tab1_p2 FOR VALUES FROM (10) TO (20);


--
-- Name: pagg_tab1_p3; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.pagg_tab1 ATTACH PARTITION public.pagg_tab1_p3 FOR VALUES FROM (20) TO (30);


--
-- Name: pagg_tab2_p1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.pagg_tab2 ATTACH PARTITION public.pagg_tab2_p1 FOR VALUES FROM (0) TO (10);


--
-- Name: pagg_tab2_p2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.pagg_tab2 ATTACH PARTITION public.pagg_tab2_p2 FOR VALUES FROM (10) TO (20);


--
-- Name: pagg_tab2_p3; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.pagg_tab2 ATTACH PARTITION public.pagg_tab2_p3 FOR VALUES FROM (20) TO (30);


--
-- Name: pagg_tab_m_p1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.pagg_tab_m ATTACH PARTITION public.pagg_tab_m_p1 FOR VALUES FROM (0, 0) TO (12, 12);


--
-- Name: pagg_tab_m_p2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.pagg_tab_m ATTACH PARTITION public.pagg_tab_m_p2 FOR VALUES FROM (12, 12) TO (22, 22);


--
-- Name: pagg_tab_m_p3; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.pagg_tab_m ATTACH PARTITION public.pagg_tab_m_p3 FOR VALUES FROM (22, 22) TO (30, 30);


--
-- Name: pagg_tab_ml_p1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.pagg_tab_ml ATTACH PARTITION public.pagg_tab_ml_p1 FOR VALUES FROM (0) TO (12);


--
-- Name: pagg_tab_ml_p2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.pagg_tab_ml ATTACH PARTITION public.pagg_tab_ml_p2 FOR VALUES FROM (12) TO (20);


--
-- Name: pagg_tab_ml_p2_s1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.pagg_tab_ml_p2 ATTACH PARTITION public.pagg_tab_ml_p2_s1 FOR VALUES IN ('0000', '0001', '0002');


--
-- Name: pagg_tab_ml_p2_s2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.pagg_tab_ml_p2 ATTACH PARTITION public.pagg_tab_ml_p2_s2 FOR VALUES IN ('0003');


--
-- Name: pagg_tab_ml_p3; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.pagg_tab_ml ATTACH PARTITION public.pagg_tab_ml_p3 FOR VALUES FROM (20) TO (30);


--
-- Name: pagg_tab_ml_p3_s1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.pagg_tab_ml_p3 ATTACH PARTITION public.pagg_tab_ml_p3_s1 FOR VALUES FROM (0) TO (7);


--
-- Name: pagg_tab_ml_p3_s2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.pagg_tab_ml_p3 ATTACH PARTITION public.pagg_tab_ml_p3_s2 FOR VALUES FROM (7) TO (10);


--
-- Name: pagg_tab_p1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.pagg_tab ATTACH PARTITION public.pagg_tab_p1 FOR VALUES IN ('0000', '0001', '0002', '0003', '0004');


--
-- Name: pagg_tab_p2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.pagg_tab ATTACH PARTITION public.pagg_tab_p2 FOR VALUES IN ('0005', '0006', '0007', '0008');


--
-- Name: pagg_tab_p3; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.pagg_tab ATTACH PARTITION public.pagg_tab_p3 FOR VALUES IN ('0009', '0010', '0011');


--
-- Name: pagg_tab_para_p1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.pagg_tab_para ATTACH PARTITION public.pagg_tab_para_p1 FOR VALUES FROM (0) TO (12);


--
-- Name: pagg_tab_para_p2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.pagg_tab_para ATTACH PARTITION public.pagg_tab_para_p2 FOR VALUES FROM (12) TO (22);


--
-- Name: pagg_tab_para_p3; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.pagg_tab_para ATTACH PARTITION public.pagg_tab_para_p3 FOR VALUES FROM (22) TO (30);


--
-- Name: part1_self_fk; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.parted_self_fk ATTACH PARTITION public.part1_self_fk FOR VALUES FROM ('0') TO ('10');


--
-- Name: part2_self_fk; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.parted_self_fk ATTACH PARTITION public.part2_self_fk FOR VALUES FROM ('10') TO ('20');


--
-- Name: part32_self_fk; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.part3_self_fk ATTACH PARTITION public.part32_self_fk FOR VALUES FROM ('20') TO ('30');


--
-- Name: part33_self_fk; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.part3_self_fk ATTACH PARTITION public.part33_self_fk FOR VALUES FROM ('30') TO ('40');


--
-- Name: part3_self_fk; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.parted_self_fk ATTACH PARTITION public.part3_self_fk FOR VALUES FROM ('20') TO ('40');


--
-- Name: part_7_a_null; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.part_7 ATTACH PARTITION public.part_7_a_null FOR VALUES IN ('a', NULL);


--
-- Name: part_p1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.part ATTACH PARTITION public.part_p1 FOR VALUES IN ('-2', '-1', 0, 1, 2);


--
-- Name: part_p2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.part ATTACH PARTITION public.part_p2 DEFAULT;


--
-- Name: part_p2_p1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.part_p2 ATTACH PARTITION public.part_p2_p1 DEFAULT;


--
-- Name: part_rev; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.part ATTACH PARTITION public.part_rev FOR VALUES IN (3);


--
-- Name: pht1_e_p1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.pht1_e ATTACH PARTITION public.pht1_e_p1 FOR VALUES WITH (modulus 3, remainder 0);


--
-- Name: pht1_e_p2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.pht1_e ATTACH PARTITION public.pht1_e_p2 FOR VALUES WITH (modulus 3, remainder 1);


--
-- Name: pht1_e_p3; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.pht1_e ATTACH PARTITION public.pht1_e_p3 FOR VALUES WITH (modulus 3, remainder 2);


--
-- Name: pht1_p1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.pht1 ATTACH PARTITION public.pht1_p1 FOR VALUES WITH (modulus 3, remainder 0);


--
-- Name: pht1_p2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.pht1 ATTACH PARTITION public.pht1_p2 FOR VALUES WITH (modulus 3, remainder 1);


--
-- Name: pht1_p3; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.pht1 ATTACH PARTITION public.pht1_p3 FOR VALUES WITH (modulus 3, remainder 2);


--
-- Name: pht2_p1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.pht2 ATTACH PARTITION public.pht2_p1 FOR VALUES WITH (modulus 3, remainder 0);


--
-- Name: pht2_p2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.pht2 ATTACH PARTITION public.pht2_p2 FOR VALUES WITH (modulus 3, remainder 1);


--
-- Name: pht2_p3; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.pht2 ATTACH PARTITION public.pht2_p3 FOR VALUES WITH (modulus 3, remainder 2);


--
-- Name: pitest1_p1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.pitest1 ATTACH PARTITION public.pitest1_p1 FOR VALUES FROM ('2016-07-01') TO ('2016-08-01');


--
-- Name: pitest1_p2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.pitest1 ATTACH PARTITION public.pitest1_p2 FOR VALUES FROM ('2016-08-01') TO ('2016-09-01');


--
-- Name: pitest2_p2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.pitest2 ATTACH PARTITION public.pitest2_p2 FOR VALUES FROM ('2016-08-01') TO ('2016-09-01');


--
-- Name: plt1_e_p1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.plt1_e ATTACH PARTITION public.plt1_e_p1 FOR VALUES IN ('0000', '0003', '0004', '0010');


--
-- Name: plt1_e_p2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.plt1_e ATTACH PARTITION public.plt1_e_p2 FOR VALUES IN ('0001', '0005', '0002', '0009');


--
-- Name: plt1_e_p3; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.plt1_e ATTACH PARTITION public.plt1_e_p3 FOR VALUES IN ('0006', '0007', '0008', '0011');


--
-- Name: plt1_p1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.plt1 ATTACH PARTITION public.plt1_p1 FOR VALUES IN ('0000', '0003', '0004', '0010');


--
-- Name: plt1_p2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.plt1 ATTACH PARTITION public.plt1_p2 FOR VALUES IN ('0001', '0005', '0002', '0009');


--
-- Name: plt1_p3; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.plt1 ATTACH PARTITION public.plt1_p3 DEFAULT;


--
-- Name: plt2_p1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.plt2 ATTACH PARTITION public.plt2_p1 FOR VALUES IN ('0000', '0003', '0004', '0010');


--
-- Name: plt2_p2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.plt2 ATTACH PARTITION public.plt2_p2 FOR VALUES IN ('0001', '0005', '0002', '0009');


--
-- Name: plt2_p3; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.plt2 ATTACH PARTITION public.plt2_p3 DEFAULT;


--
-- Name: prt1_e_p1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.prt1_e ATTACH PARTITION public.prt1_e_p1 FOR VALUES FROM (0) TO (250);


--
-- Name: prt1_e_p2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.prt1_e ATTACH PARTITION public.prt1_e_p2 FOR VALUES FROM (250) TO (500);


--
-- Name: prt1_e_p3; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.prt1_e ATTACH PARTITION public.prt1_e_p3 FOR VALUES FROM (500) TO (600);


--
-- Name: prt1_l_p1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.prt1_l ATTACH PARTITION public.prt1_l_p1 FOR VALUES FROM (0) TO (250);


--
-- Name: prt1_l_p2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.prt1_l ATTACH PARTITION public.prt1_l_p2 FOR VALUES FROM (250) TO (500);


--
-- Name: prt1_l_p2_p1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.prt1_l_p2 ATTACH PARTITION public.prt1_l_p2_p1 FOR VALUES IN ('0000', '0001');


--
-- Name: prt1_l_p2_p2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.prt1_l_p2 ATTACH PARTITION public.prt1_l_p2_p2 FOR VALUES IN ('0002', '0003');


--
-- Name: prt1_l_p3; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.prt1_l ATTACH PARTITION public.prt1_l_p3 FOR VALUES FROM (500) TO (600);


--
-- Name: prt1_l_p3_p1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.prt1_l_p3 ATTACH PARTITION public.prt1_l_p3_p1 FOR VALUES FROM (0) TO (13);


--
-- Name: prt1_l_p3_p2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.prt1_l_p3 ATTACH PARTITION public.prt1_l_p3_p2 FOR VALUES FROM (13) TO (25);


--
-- Name: prt1_m_p1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.prt1_m ATTACH PARTITION public.prt1_m_p1 FOR VALUES FROM (0, 0) TO (250, 250);


--
-- Name: prt1_m_p2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.prt1_m ATTACH PARTITION public.prt1_m_p2 FOR VALUES FROM (250, 250) TO (500, 500);


--
-- Name: prt1_m_p3; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.prt1_m ATTACH PARTITION public.prt1_m_p3 FOR VALUES FROM (500, 500) TO (600, 600);


--
-- Name: prt1_n_p1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.prt1_n ATTACH PARTITION public.prt1_n_p1 FOR VALUES FROM ('0000') TO ('0250');


--
-- Name: prt1_n_p2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.prt1_n ATTACH PARTITION public.prt1_n_p2 FOR VALUES FROM ('0250') TO ('0500');


--
-- Name: prt1_p1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.prt1 ATTACH PARTITION public.prt1_p1 FOR VALUES FROM (0) TO (250);


--
-- Name: prt1_p2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.prt1 ATTACH PARTITION public.prt1_p2 FOR VALUES FROM (250) TO (500);


--
-- Name: prt1_p3; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.prt1 ATTACH PARTITION public.prt1_p3 DEFAULT;


--
-- Name: prt2_e_p1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.prt2_e ATTACH PARTITION public.prt2_e_p1 FOR VALUES FROM (0) TO (250);


--
-- Name: prt2_e_p2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.prt2_e ATTACH PARTITION public.prt2_e_p2 FOR VALUES FROM (250) TO (500);


--
-- Name: prt2_e_p3; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.prt2_e ATTACH PARTITION public.prt2_e_p3 FOR VALUES FROM (500) TO (600);


--
-- Name: prt2_l_p1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.prt2_l ATTACH PARTITION public.prt2_l_p1 FOR VALUES FROM (0) TO (250);


--
-- Name: prt2_l_p2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.prt2_l ATTACH PARTITION public.prt2_l_p2 FOR VALUES FROM (250) TO (500);


--
-- Name: prt2_l_p2_p1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.prt2_l_p2 ATTACH PARTITION public.prt2_l_p2_p1 FOR VALUES IN ('0000', '0001');


--
-- Name: prt2_l_p2_p2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.prt2_l_p2 ATTACH PARTITION public.prt2_l_p2_p2 FOR VALUES IN ('0002', '0003');


--
-- Name: prt2_l_p3; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.prt2_l ATTACH PARTITION public.prt2_l_p3 FOR VALUES FROM (500) TO (600);


--
-- Name: prt2_l_p3_p1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.prt2_l_p3 ATTACH PARTITION public.prt2_l_p3_p1 FOR VALUES FROM (0) TO (13);


--
-- Name: prt2_l_p3_p2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.prt2_l_p3 ATTACH PARTITION public.prt2_l_p3_p2 FOR VALUES FROM (13) TO (25);


--
-- Name: prt2_m_p1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.prt2_m ATTACH PARTITION public.prt2_m_p1 FOR VALUES FROM (0, 0) TO (250, 250);


--
-- Name: prt2_m_p2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.prt2_m ATTACH PARTITION public.prt2_m_p2 FOR VALUES FROM (250, 250) TO (500, 500);


--
-- Name: prt2_m_p3; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.prt2_m ATTACH PARTITION public.prt2_m_p3 FOR VALUES FROM (500, 500) TO (600, 600);


--
-- Name: prt2_n_p1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.prt2_n ATTACH PARTITION public.prt2_n_p1 FOR VALUES IN ('0000', '0003', '0004', '0010', '0006', '0007');


--
-- Name: prt2_n_p2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.prt2_n ATTACH PARTITION public.prt2_n_p2 FOR VALUES IN ('0001', '0005', '0002', '0009', '0008', '0011');


--
-- Name: prt2_p1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.prt2 ATTACH PARTITION public.prt2_p1 FOR VALUES FROM (0) TO (250);


--
-- Name: prt2_p2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.prt2 ATTACH PARTITION public.prt2_p2 FOR VALUES FROM (250) TO (500);


--
-- Name: prt2_p3; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.prt2 ATTACH PARTITION public.prt2_p3 DEFAULT;


--
-- Name: prt3_n_p1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.prt3_n ATTACH PARTITION public.prt3_n_p1 FOR VALUES IN ('0000', '0004', '0006', '0007');


--
-- Name: prt3_n_p2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.prt3_n ATTACH PARTITION public.prt3_n_p2 FOR VALUES IN ('0001', '0002', '0008', '0010');


--
-- Name: prt3_n_p3; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.prt3_n ATTACH PARTITION public.prt3_n_p3 FOR VALUES IN ('0003', '0005', '0009', '0011');


--
-- Name: prt4_n_p1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.prt4_n ATTACH PARTITION public.prt4_n_p1 FOR VALUES FROM (0) TO (300);


--
-- Name: prt4_n_p2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.prt4_n ATTACH PARTITION public.prt4_n_p2 FOR VALUES FROM (300) TO (500);


--
-- Name: prt4_n_p3; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.prt4_n ATTACH PARTITION public.prt4_n_p3 FOR VALUES FROM (500) TO (600);


--
-- Name: pt_part1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.partitioned_table ATTACH PARTITION public.pt_part1 FOR VALUES IN (1);


--
-- Name: pt_part2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.partitioned_table ATTACH PARTITION public.pt_part2 FOR VALUES IN (2);


--
-- Name: regress_constr_partition1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.regress_constr_partitioned ATTACH PARTITION public.regress_constr_partition1 FOR VALUES IN (1);


--
-- Name: tableam_parted_a_heap2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.tableam_parted_heap2 ATTACH PARTITION public.tableam_parted_a_heap2 FOR VALUES IN ('a');


--
-- Name: tableam_parted_b_heap2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.tableam_parted_heap2 ATTACH PARTITION public.tableam_parted_b_heap2 FOR VALUES IN ('b');


--
-- Name: tableam_parted_c_heap2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.tableam_parted_heap2 ATTACH PARTITION public.tableam_parted_c_heap2 FOR VALUES IN ('c');


--
-- Name: tableam_parted_d_heap2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.tableam_parted_heap2 ATTACH PARTITION public.tableam_parted_d_heap2 FOR VALUES IN ('d');


--
-- Name: trigger_parted_p1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.trigger_parted ATTACH PARTITION public.trigger_parted_p1 FOR VALUES IN (1);


--
-- Name: trigger_parted_p1_1; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.trigger_parted_p1 ATTACH PARTITION public.trigger_parted_p1_1 FOR VALUES IN (1);


--
-- Name: trigger_parted_p2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.trigger_parted ATTACH PARTITION public.trigger_parted_p2 FOR VALUES IN (2);


--
-- Name: trigger_parted_p2_2; Type: TABLE ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.trigger_parted_p2 ATTACH PARTITION public.trigger_parted_p2_2 FOR VALUES IN (2);


--
-- Name: pk1; Type: TABLE ATTACH; Schema: regress_indexing; Owner: ashutoshpg
--

ALTER TABLE ONLY regress_indexing.pk ATTACH PARTITION regress_indexing.pk1 FOR VALUES FROM (0) TO (1000);


--
-- Name: pk2; Type: TABLE ATTACH; Schema: regress_indexing; Owner: ashutoshpg
--

ALTER TABLE ONLY regress_indexing.pk ATTACH PARTITION regress_indexing.pk2 FOR VALUES FROM (1000) TO (2000);


--
-- Name: pk3; Type: TABLE ATTACH; Schema: regress_indexing; Owner: ashutoshpg
--

ALTER TABLE ONLY regress_indexing.pk ATTACH PARTITION regress_indexing.pk3 FOR VALUES FROM (2000) TO (3000);


--
-- Name: pk4; Type: TABLE ATTACH; Schema: regress_indexing; Owner: ashutoshpg
--

ALTER TABLE ONLY regress_indexing.pk ATTACH PARTITION regress_indexing.pk4 FOR VALUES FROM (3000) TO (4000);


--
-- Name: pk5; Type: TABLE ATTACH; Schema: regress_indexing; Owner: ashutoshpg
--

ALTER TABLE ONLY regress_indexing.pk ATTACH PARTITION regress_indexing.pk5 FOR VALUES FROM (4000) TO (5000);


--
-- Name: pk51; Type: TABLE ATTACH; Schema: regress_indexing; Owner: ashutoshpg
--

ALTER TABLE ONLY regress_indexing.pk5 ATTACH PARTITION regress_indexing.pk51 FOR VALUES FROM (4000) TO (4500);


--
-- Name: pk52; Type: TABLE ATTACH; Schema: regress_indexing; Owner: ashutoshpg
--

ALTER TABLE ONLY regress_indexing.pk5 ATTACH PARTITION regress_indexing.pk52 FOR VALUES FROM (4500) TO (5000);


--
-- Name: clstr_tst a; Type: DEFAULT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.clstr_tst ALTER COLUMN a SET DEFAULT nextval('public.clstr_tst_a_seq'::regclass);


--
-- Name: clstr_tst_inh a; Type: DEFAULT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.clstr_tst_inh ALTER COLUMN a SET DEFAULT nextval('public.clstr_tst_a_seq'::regclass);


--
-- Name: clstr_tst_s rf_a; Type: DEFAULT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.clstr_tst_s ALTER COLUMN rf_a SET DEFAULT nextval('public.clstr_tst_s_rf_a_seq'::regclass);


--
-- Name: itest5 a; Type: DEFAULT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.itest5 ALTER COLUMN a SET DEFAULT nextval('public.itest5_a_seq'::regclass);


--
-- Name: rules_log id; Type: DEFAULT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.rules_log ALTER COLUMN id SET DEFAULT nextval('public.rules_log_id_seq'::regclass);


--
-- Name: spgist_box_tbl id; Type: DEFAULT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.spgist_box_tbl ALTER COLUMN id SET DEFAULT nextval('public.spgist_box_tbl_id_seq'::regclass);


--
-- Name: spgist_unlogged_tbl id; Type: DEFAULT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.spgist_unlogged_tbl ALTER COLUMN id SET DEFAULT nextval('public.spgist_unlogged_tbl_id_seq'::regclass);


--
-- Name: transition_table_level1 level1_no; Type: DEFAULT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.transition_table_level1 ALTER COLUMN level1_no SET DEFAULT nextval('public.transition_table_level1_level1_no_seq'::regclass);


--
-- Name: transition_table_level2 level2_no; Type: DEFAULT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.transition_table_level2 ALTER COLUMN level2_no SET DEFAULT nextval('public.transition_table_level2_level2_no_seq'::regclass);


--
-- Name: pk pk_pkey; Type: CONSTRAINT; Schema: fkpart3; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart3.pk
    ADD CONSTRAINT pk_pkey PRIMARY KEY (a);


--
-- Name: pk1 pk1_pkey; Type: CONSTRAINT; Schema: fkpart3; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart3.pk1
    ADD CONSTRAINT pk1_pkey PRIMARY KEY (a);


--
-- Name: pk2 pk2_pkey; Type: CONSTRAINT; Schema: fkpart3; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart3.pk2
    ADD CONSTRAINT pk2_pkey PRIMARY KEY (a);


--
-- Name: pk3 pk3_pkey; Type: CONSTRAINT; Schema: fkpart3; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart3.pk3
    ADD CONSTRAINT pk3_pkey PRIMARY KEY (a);


--
-- Name: pk4 pk4_pkey; Type: CONSTRAINT; Schema: fkpart3; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart3.pk4
    ADD CONSTRAINT pk4_pkey PRIMARY KEY (a);


--
-- Name: pk5 pk5_pkey; Type: CONSTRAINT; Schema: fkpart3; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart3.pk5
    ADD CONSTRAINT pk5_pkey PRIMARY KEY (a);


--
-- Name: pk51 pk51_pkey; Type: CONSTRAINT; Schema: fkpart3; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart3.pk51
    ADD CONSTRAINT pk51_pkey PRIMARY KEY (a);


--
-- Name: pk52 pk52_pkey; Type: CONSTRAINT; Schema: fkpart3; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart3.pk52
    ADD CONSTRAINT pk52_pkey PRIMARY KEY (a);


--
-- Name: droppk droppk_pkey; Type: CONSTRAINT; Schema: fkpart4; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart4.droppk
    ADD CONSTRAINT droppk_pkey PRIMARY KEY (a);


--
-- Name: droppk1 droppk1_pkey; Type: CONSTRAINT; Schema: fkpart4; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart4.droppk1
    ADD CONSTRAINT droppk1_pkey PRIMARY KEY (a);


--
-- Name: droppk21 droppk21_pkey; Type: CONSTRAINT; Schema: fkpart4; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart4.droppk21
    ADD CONSTRAINT droppk21_pkey PRIMARY KEY (a);


--
-- Name: droppk2 droppk2_pkey; Type: CONSTRAINT; Schema: fkpart4; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart4.droppk2
    ADD CONSTRAINT droppk2_pkey PRIMARY KEY (a);


--
-- Name: droppk2_d droppk2_d_pkey; Type: CONSTRAINT; Schema: fkpart4; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart4.droppk2_d
    ADD CONSTRAINT droppk2_d_pkey PRIMARY KEY (a);


--
-- Name: droppk_d droppk_d_pkey; Type: CONSTRAINT; Schema: fkpart4; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart4.droppk_d
    ADD CONSTRAINT droppk_d_pkey PRIMARY KEY (a);


--
-- Name: pk pk_pkey; Type: CONSTRAINT; Schema: fkpart5; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart5.pk
    ADD CONSTRAINT pk_pkey PRIMARY KEY (a);


--
-- Name: pk1 pk1_pkey; Type: CONSTRAINT; Schema: fkpart5; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart5.pk1
    ADD CONSTRAINT pk1_pkey PRIMARY KEY (a);


--
-- Name: pk11 pk11_pkey; Type: CONSTRAINT; Schema: fkpart5; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart5.pk11
    ADD CONSTRAINT pk11_pkey PRIMARY KEY (a);


--
-- Name: pk2 pk2_pkey; Type: CONSTRAINT; Schema: fkpart5; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart5.pk2
    ADD CONSTRAINT pk2_pkey PRIMARY KEY (a);


--
-- Name: pk3 pk3_pkey; Type: CONSTRAINT; Schema: fkpart5; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart5.pk3
    ADD CONSTRAINT pk3_pkey PRIMARY KEY (a);


--
-- Name: pk31 pk31_pkey; Type: CONSTRAINT; Schema: fkpart5; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart5.pk31
    ADD CONSTRAINT pk31_pkey PRIMARY KEY (a);


--
-- Name: pk32 pk32_pkey; Type: CONSTRAINT; Schema: fkpart5; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart5.pk32
    ADD CONSTRAINT pk32_pkey PRIMARY KEY (a);


--
-- Name: pk pk_pkey; Type: CONSTRAINT; Schema: fkpart6; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart6.pk
    ADD CONSTRAINT pk_pkey PRIMARY KEY (a);


--
-- Name: pk1 pk1_pkey; Type: CONSTRAINT; Schema: fkpart6; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart6.pk1
    ADD CONSTRAINT pk1_pkey PRIMARY KEY (a);


--
-- Name: pk11 pk11_pkey; Type: CONSTRAINT; Schema: fkpart6; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart6.pk11
    ADD CONSTRAINT pk11_pkey PRIMARY KEY (a);


--
-- Name: pk12 pk12_pkey; Type: CONSTRAINT; Schema: fkpart6; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart6.pk12
    ADD CONSTRAINT pk12_pkey PRIMARY KEY (a);


--
-- Name: gtest20b chk; Type: CHECK CONSTRAINT; Schema: generated_stored_tests; Owner: ashutoshpg
--

ALTER TABLE generated_stored_tests.gtest20b
    ADD CONSTRAINT chk CHECK ((b < 50)) NOT VALID;


--
-- Name: gtest0 gtest0_pkey; Type: CONSTRAINT; Schema: generated_stored_tests; Owner: ashutoshpg
--

ALTER TABLE ONLY generated_stored_tests.gtest0
    ADD CONSTRAINT gtest0_pkey PRIMARY KEY (a);


--
-- Name: gtest10 gtest10_pkey; Type: CONSTRAINT; Schema: generated_stored_tests; Owner: ashutoshpg
--

ALTER TABLE ONLY generated_stored_tests.gtest10
    ADD CONSTRAINT gtest10_pkey PRIMARY KEY (a);


--
-- Name: gtest10a gtest10a_pkey; Type: CONSTRAINT; Schema: generated_stored_tests; Owner: ashutoshpg
--

ALTER TABLE ONLY generated_stored_tests.gtest10a
    ADD CONSTRAINT gtest10a_pkey PRIMARY KEY (a);


--
-- Name: gtest1 gtest1_pkey; Type: CONSTRAINT; Schema: generated_stored_tests; Owner: ashutoshpg
--

ALTER TABLE ONLY generated_stored_tests.gtest1
    ADD CONSTRAINT gtest1_pkey PRIMARY KEY (a);


--
-- Name: gtest20 gtest20_pkey; Type: CONSTRAINT; Schema: generated_stored_tests; Owner: ashutoshpg
--

ALTER TABLE ONLY generated_stored_tests.gtest20
    ADD CONSTRAINT gtest20_pkey PRIMARY KEY (a);


--
-- Name: gtest20a gtest20a_pkey; Type: CONSTRAINT; Schema: generated_stored_tests; Owner: ashutoshpg
--

ALTER TABLE ONLY generated_stored_tests.gtest20a
    ADD CONSTRAINT gtest20a_pkey PRIMARY KEY (a);


--
-- Name: gtest20b gtest20b_pkey; Type: CONSTRAINT; Schema: generated_stored_tests; Owner: ashutoshpg
--

ALTER TABLE ONLY generated_stored_tests.gtest20b
    ADD CONSTRAINT gtest20b_pkey PRIMARY KEY (a);


--
-- Name: gtest21a gtest21a_pkey; Type: CONSTRAINT; Schema: generated_stored_tests; Owner: ashutoshpg
--

ALTER TABLE ONLY generated_stored_tests.gtest21a
    ADD CONSTRAINT gtest21a_pkey PRIMARY KEY (a);


--
-- Name: gtest21b gtest21b_pkey; Type: CONSTRAINT; Schema: generated_stored_tests; Owner: ashutoshpg
--

ALTER TABLE ONLY generated_stored_tests.gtest21b
    ADD CONSTRAINT gtest21b_pkey PRIMARY KEY (a);


--
-- Name: gtest22a gtest22a_b_key; Type: CONSTRAINT; Schema: generated_stored_tests; Owner: ashutoshpg
--

ALTER TABLE ONLY generated_stored_tests.gtest22a
    ADD CONSTRAINT gtest22a_b_key UNIQUE (b);


--
-- Name: gtest22a gtest22a_pkey; Type: CONSTRAINT; Schema: generated_stored_tests; Owner: ashutoshpg
--

ALTER TABLE ONLY generated_stored_tests.gtest22a
    ADD CONSTRAINT gtest22a_pkey PRIMARY KEY (a);


--
-- Name: gtest22b gtest22b_pkey; Type: CONSTRAINT; Schema: generated_stored_tests; Owner: ashutoshpg
--

ALTER TABLE ONLY generated_stored_tests.gtest22b
    ADD CONSTRAINT gtest22b_pkey PRIMARY KEY (a, b);


--
-- Name: gtest23p gtest23p_pkey; Type: CONSTRAINT; Schema: generated_stored_tests; Owner: ashutoshpg
--

ALTER TABLE ONLY generated_stored_tests.gtest23p
    ADD CONSTRAINT gtest23p_pkey PRIMARY KEY (y);


--
-- Name: gtest23q gtest23q_pkey; Type: CONSTRAINT; Schema: generated_stored_tests; Owner: ashutoshpg
--

ALTER TABLE ONLY generated_stored_tests.gtest23q
    ADD CONSTRAINT gtest23q_pkey PRIMARY KEY (a);


--
-- Name: gtest24 gtest24_pkey; Type: CONSTRAINT; Schema: generated_stored_tests; Owner: ashutoshpg
--

ALTER TABLE ONLY generated_stored_tests.gtest24
    ADD CONSTRAINT gtest24_pkey PRIMARY KEY (a);


--
-- Name: gtest25 gtest25_pkey; Type: CONSTRAINT; Schema: generated_stored_tests; Owner: ashutoshpg
--

ALTER TABLE ONLY generated_stored_tests.gtest25
    ADD CONSTRAINT gtest25_pkey PRIMARY KEY (a);


--
-- Name: gtest26 gtest26_pkey; Type: CONSTRAINT; Schema: generated_stored_tests; Owner: ashutoshpg
--

ALTER TABLE ONLY generated_stored_tests.gtest26
    ADD CONSTRAINT gtest26_pkey PRIMARY KEY (a);


--
-- Name: gtest2 gtest2_pkey; Type: CONSTRAINT; Schema: generated_stored_tests; Owner: ashutoshpg
--

ALTER TABLE ONLY generated_stored_tests.gtest2
    ADD CONSTRAINT gtest2_pkey PRIMARY KEY (a);


--
-- Name: gtest_tableoid gtest_tableoid_pkey; Type: CONSTRAINT; Schema: generated_stored_tests; Owner: ashutoshpg
--

ALTER TABLE ONLY generated_stored_tests.gtest_tableoid
    ADD CONSTRAINT gtest_tableoid_pkey PRIMARY KEY (a);


--
-- Name: alter_table_under_transition_tables alter_table_under_transition_tables_pkey; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.alter_table_under_transition_tables
    ADD CONSTRAINT alter_table_under_transition_tables_pkey PRIMARY KEY (id);


--
-- Name: atnotnull1 atnotnull1_pkey; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.atnotnull1
    ADD CONSTRAINT atnotnull1_pkey PRIMARY KEY (c);


--
-- Name: check_con_tbl check_con_tbl_check; Type: CHECK CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE public.check_con_tbl
    ADD CONSTRAINT check_con_tbl_check CHECK (public.check_con_function(check_con_tbl.*));


--
-- Name: clstr_tst clstr_tst_pkey; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.clstr_tst
    ADD CONSTRAINT clstr_tst_pkey PRIMARY KEY (a);


--
-- Name: clstr_tst_s clstr_tst_s_pkey; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.clstr_tst_s
    ADD CONSTRAINT clstr_tst_s_pkey PRIMARY KEY (rf_a);


--
-- Name: cnn_uq cnn_uq_idx; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.cnn_uq
    ADD CONSTRAINT cnn_uq_idx UNIQUE (a);


--
-- Name: comment_test comment_test_pk; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.comment_test
    ADD CONSTRAINT comment_test_pk PRIMARY KEY (id);


--
-- Name: CONSTRAINT comment_test_pk ON comment_test; Type: COMMENT; Schema: public; Owner: ashutoshpg
--

COMMENT ON CONSTRAINT comment_test_pk ON public.comment_test IS 'PRIMARY KEY constraint of comment_test';


--
-- Name: customer customer_pkey; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.customer
    ADD CONSTRAINT customer_pkey PRIMARY KEY (cid);


--
-- Name: delete_test_table delete_test_table_pkey; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.delete_test_table
    ADD CONSTRAINT delete_test_table_pkey PRIMARY KEY (a, b, c, d);


--
-- Name: ec0 ec0_pkey; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.ec0
    ADD CONSTRAINT ec0_pkey PRIMARY KEY (ff);


--
-- Name: ec1 ec1_pkey; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.ec1
    ADD CONSTRAINT ec1_pkey PRIMARY KEY (ff);


--
-- Name: ec2 ec2_pkey; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.ec2
    ADD CONSTRAINT ec2_pkey PRIMARY KEY (xf);


--
-- Name: fk_notpartitioned_pk fk_notpartitioned_pk_pkey; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.fk_notpartitioned_pk
    ADD CONSTRAINT fk_notpartitioned_pk_pkey PRIMARY KEY (a, b);


--
-- Name: idxpart_another idxpart_another_pkey; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.idxpart_another
    ADD CONSTRAINT idxpart_another_pkey PRIMARY KEY (a, b);


--
-- Name: idxpart_another_1 idxpart_another_1_pkey; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.idxpart_another_1
    ADD CONSTRAINT idxpart_another_1_pkey PRIMARY KEY (a, b);


--
-- Name: invalid_check_con inh_check_constraint; Type: CHECK CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE public.invalid_check_con
    ADD CONSTRAINT inh_check_constraint CHECK ((f1 > 0)) NOT VALID;


--
-- Name: inhx inhx_pkey; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.inhx
    ADD CONSTRAINT inhx_pkey PRIMARY KEY (xx);


--
-- Name: mvtest_t mvtest_t_pkey; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.mvtest_t
    ADD CONSTRAINT mvtest_t_pkey PRIMARY KEY (id);


--
-- Name: notnull_tbl4_cld2 notnull_tbl4_cld2_pkey; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.notnull_tbl4_cld2
    ADD CONSTRAINT notnull_tbl4_cld2_pkey PRIMARY KEY (a) DEFERRABLE;


--
-- Name: notnull_tbl4_cld3 notnull_tbl4_cld3_pkey; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.notnull_tbl4_cld3
    ADD CONSTRAINT notnull_tbl4_cld3_pkey PRIMARY KEY (a) DEFERRABLE;


--
-- Name: notnull_tbl4_lk2 notnull_tbl4_lk2_pkey; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.notnull_tbl4_lk2
    ADD CONSTRAINT notnull_tbl4_lk2_pkey PRIMARY KEY (a) DEFERRABLE INITIALLY DEFERRED;


--
-- Name: notnull_tbl4_lk3 notnull_tbl4_lk3_pkey; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.notnull_tbl4_lk3
    ADD CONSTRAINT notnull_tbl4_lk3_pkey PRIMARY KEY (a) DEFERRABLE INITIALLY DEFERRED;


--
-- Name: notnull_tbl4 notnull_tbl4_pkey; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.notnull_tbl4
    ADD CONSTRAINT notnull_tbl4_pkey PRIMARY KEY (a) DEFERRABLE INITIALLY DEFERRED;


--
-- Name: nv_child_2010 nv_child_2010_d_check; Type: CHECK CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE public.nv_child_2010
    ADD CONSTRAINT nv_child_2010_d_check CHECK (((d >= '2010-01-01'::date) AND (d <= '2010-12-31'::date))) NOT VALID;


--
-- Name: nv_parent nv_parent_d_check; Type: CHECK CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE public.nv_parent
    ADD CONSTRAINT nv_parent_d_check CHECK (((d >= '2001-01-01'::date) AND (d <= '2099-12-31'::date))) NOT VALID;


--
-- Name: parted_self_fk parted_self_fk_pkey; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.parted_self_fk
    ADD CONSTRAINT parted_self_fk_pkey PRIMARY KEY (id);


--
-- Name: part1_self_fk part1_self_fk_pkey; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.part1_self_fk
    ADD CONSTRAINT part1_self_fk_pkey PRIMARY KEY (id);


--
-- Name: part2_self_fk part2_self_fk_pkey; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.part2_self_fk
    ADD CONSTRAINT part2_self_fk_pkey PRIMARY KEY (id);


--
-- Name: part3_self_fk part3_self_fk_pkey; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.part3_self_fk
    ADD CONSTRAINT part3_self_fk_pkey PRIMARY KEY (id);


--
-- Name: part32_self_fk part32_self_fk_pkey; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.part32_self_fk
    ADD CONSTRAINT part32_self_fk_pkey PRIMARY KEY (id);


--
-- Name: part33_self_fk part33_self_fk_pkey; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.part33_self_fk
    ADD CONSTRAINT part33_self_fk_pkey PRIMARY KEY (id);


--
-- Name: persons2 persons2_name_key; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.persons2
    ADD CONSTRAINT persons2_name_key UNIQUE (name);


--
-- Name: persons2 persons2_pkey; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.persons2
    ADD CONSTRAINT persons2_pkey PRIMARY KEY (id);


--
-- Name: persons3 persons3_pkey; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.persons3
    ADD CONSTRAINT persons3_pkey PRIMARY KEY (id);


--
-- Name: pp1 pp1_pkey; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.pp1
    ADD CONSTRAINT pp1_pkey PRIMARY KEY (f1);


--
-- Name: regress_constr_partition1 regress_constr_partition1_pkey; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.regress_constr_partition1
    ADD CONSTRAINT regress_constr_partition1_pkey PRIMARY KEY (a);


--
-- Name: rule_and_refint_t1 rule_and_refint_t1_pkey; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.rule_and_refint_t1
    ADD CONSTRAINT rule_and_refint_t1_pkey PRIMARY KEY (id1a, id1b);


--
-- Name: rule_and_refint_t2 rule_and_refint_t2_pkey; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.rule_and_refint_t2
    ADD CONSTRAINT rule_and_refint_t2_pkey PRIMARY KEY (id2a, id2c);


--
-- Name: rule_and_refint_t3 rule_and_refint_t3_pkey; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.rule_and_refint_t3
    ADD CONSTRAINT rule_and_refint_t3_pkey PRIMARY KEY (id3a, id3b, id3c);


--
-- Name: skip_wal_skip_rewrite_index skip_wal_skip_rewrite_index_pkey; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.skip_wal_skip_rewrite_index
    ADD CONSTRAINT skip_wal_skip_rewrite_index_pkey PRIMARY KEY (c);


--
-- Name: tbl_include_box tbl_include_box_idx_unique; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.tbl_include_box
    ADD CONSTRAINT tbl_include_box_idx_unique PRIMARY KEY (c1, c2) INCLUDE (c3, c4);


--
-- Name: tbl_include_pk tbl_include_pk_pkey; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.tbl_include_pk
    ADD CONSTRAINT tbl_include_pk_pkey PRIMARY KEY (c1, c2) INCLUDE (c3, c4);


--
-- Name: tbl_include_unique1 tbl_include_unique1_c1_c2_c3_c4_key; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.tbl_include_unique1
    ADD CONSTRAINT tbl_include_unique1_c1_c2_c3_c4_key UNIQUE (c1, c2) INCLUDE (c3, c4);


--
-- Name: tbl_include_unique1 tbl_include_unique1_idx_unique; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.tbl_include_unique1
    ADD CONSTRAINT tbl_include_unique1_idx_unique UNIQUE (c1, c2) INCLUDE (c3, c4);


--
-- Name: temporal_fk2_mltrng2mltrng temporal_fk2_mltrng2mltrng_pk; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.temporal_fk2_mltrng2mltrng
    ADD CONSTRAINT temporal_fk2_mltrng2mltrng_pk PRIMARY KEY (id, valid_at WITHOUT OVERLAPS);


--
-- Name: temporal_fk2_rng2rng temporal_fk2_rng2rng_pk; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.temporal_fk2_rng2rng
    ADD CONSTRAINT temporal_fk2_rng2rng_pk PRIMARY KEY (id, valid_at WITHOUT OVERLAPS);


--
-- Name: temporal_fk_mltrng2mltrng temporal_fk_mltrng2mltrng_pk; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.temporal_fk_mltrng2mltrng
    ADD CONSTRAINT temporal_fk_mltrng2mltrng_pk PRIMARY KEY (id, valid_at WITHOUT OVERLAPS);


--
-- Name: temporal_fk_rng2rng temporal_fk_rng2rng_pk; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.temporal_fk_rng2rng
    ADD CONSTRAINT temporal_fk_rng2rng_pk PRIMARY KEY (id, valid_at WITHOUT OVERLAPS);


--
-- Name: temporal_mltrng2 temporal_mltrng2_pk; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.temporal_mltrng2
    ADD CONSTRAINT temporal_mltrng2_pk PRIMARY KEY (id1, id2, valid_at WITHOUT OVERLAPS);


--
-- Name: temporal_mltrng temporal_mltrng_pk; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.temporal_mltrng
    ADD CONSTRAINT temporal_mltrng_pk PRIMARY KEY (id, valid_at WITHOUT OVERLAPS);


--
-- Name: temporal_rng2 temporal_rng2_pk; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.temporal_rng2
    ADD CONSTRAINT temporal_rng2_pk PRIMARY KEY (id1, id2, valid_at WITHOUT OVERLAPS);


--
-- Name: temporal_rng temporal_rng_pk; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.temporal_rng
    ADD CONSTRAINT temporal_rng_pk PRIMARY KEY (id, valid_at WITHOUT OVERLAPS);


--
-- Name: test_range_excl test_range_excl_room_during_excl; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.test_range_excl
    ADD CONSTRAINT test_range_excl_room_during_excl EXCLUDE USING gist (room WITH =, during WITH &&);


--
-- Name: test_range_excl test_range_excl_speaker_during_excl; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.test_range_excl
    ADD CONSTRAINT test_range_excl_speaker_during_excl EXCLUDE USING gist (speaker WITH =, during WITH &&);


--
-- Name: transition_table_base transition_table_base_pkey; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.transition_table_base
    ADD CONSTRAINT transition_table_base_pkey PRIMARY KEY (id);


--
-- Name: transition_table_level1 transition_table_level1_pkey; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.transition_table_level1
    ADD CONSTRAINT transition_table_level1_pkey PRIMARY KEY (level1_no);


--
-- Name: transition_table_level2 transition_table_level2_pkey; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.transition_table_level2
    ADD CONSTRAINT transition_table_level2_pkey PRIMARY KEY (level2_no);


--
-- Name: transition_table_status transition_table_status_pkey; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.transition_table_status
    ADD CONSTRAINT transition_table_status_pkey PRIMARY KEY (level, node_no);


--
-- Name: trigger_parted trigger_parted_pkey; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.trigger_parted
    ADD CONSTRAINT trigger_parted_pkey PRIMARY KEY (a);


--
-- Name: trigger_parted_p1 trigger_parted_p1_pkey; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.trigger_parted_p1
    ADD CONSTRAINT trigger_parted_p1_pkey PRIMARY KEY (a);


--
-- Name: trigger_parted_p1_1 trigger_parted_p1_1_pkey; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.trigger_parted_p1_1
    ADD CONSTRAINT trigger_parted_p1_1_pkey PRIMARY KEY (a);


--
-- Name: trigger_parted_p2 trigger_parted_p2_pkey; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.trigger_parted_p2
    ADD CONSTRAINT trigger_parted_p2_pkey PRIMARY KEY (a);


--
-- Name: trigger_parted_p2_2 trigger_parted_p2_2_pkey; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.trigger_parted_p2_2
    ADD CONSTRAINT trigger_parted_p2_2_pkey PRIMARY KEY (a);


--
-- Name: utf8_verification_inputs utf8_verification_inputs_pkey; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.utf8_verification_inputs
    ADD CONSTRAINT utf8_verification_inputs_pkey PRIMARY KEY (description);


--
-- Name: view_base_table view_base_table_pkey; Type: CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.view_base_table
    ADD CONSTRAINT view_base_table_pkey PRIMARY KEY (key);


--
-- Name: pk pk_pkey; Type: CONSTRAINT; Schema: regress_indexing; Owner: ashutoshpg
--

ALTER TABLE ONLY regress_indexing.pk
    ADD CONSTRAINT pk_pkey PRIMARY KEY (a);


--
-- Name: pk1 pk1_pkey; Type: CONSTRAINT; Schema: regress_indexing; Owner: ashutoshpg
--

ALTER TABLE ONLY regress_indexing.pk1
    ADD CONSTRAINT pk1_pkey PRIMARY KEY (a);


--
-- Name: pk2 pk2_pkey; Type: CONSTRAINT; Schema: regress_indexing; Owner: ashutoshpg
--

ALTER TABLE ONLY regress_indexing.pk2
    ADD CONSTRAINT pk2_pkey PRIMARY KEY (a);


--
-- Name: pk3 pk3_pkey; Type: CONSTRAINT; Schema: regress_indexing; Owner: ashutoshpg
--

ALTER TABLE ONLY regress_indexing.pk3
    ADD CONSTRAINT pk3_pkey PRIMARY KEY (a);


--
-- Name: pk4 pk4_pkey; Type: CONSTRAINT; Schema: regress_indexing; Owner: ashutoshpg
--

ALTER TABLE ONLY regress_indexing.pk4
    ADD CONSTRAINT pk4_pkey PRIMARY KEY (a);


--
-- Name: pk5 pk5_pkey; Type: CONSTRAINT; Schema: regress_indexing; Owner: ashutoshpg
--

ALTER TABLE ONLY regress_indexing.pk5
    ADD CONSTRAINT pk5_pkey PRIMARY KEY (a);


--
-- Name: pk51 pk51_pkey; Type: CONSTRAINT; Schema: regress_indexing; Owner: ashutoshpg
--

ALTER TABLE ONLY regress_indexing.pk51
    ADD CONSTRAINT pk51_pkey PRIMARY KEY (a);


--
-- Name: pk52 pk52_pkey; Type: CONSTRAINT; Schema: regress_indexing; Owner: ashutoshpg
--

ALTER TABLE ONLY regress_indexing.pk52
    ADD CONSTRAINT pk52_pkey PRIMARY KEY (a);


--
-- Name: gtest22c_b_idx; Type: INDEX; Schema: generated_stored_tests; Owner: ashutoshpg
--

CREATE INDEX gtest22c_b_idx ON generated_stored_tests.gtest22c USING btree (b);


--
-- Name: gtest22c_expr_idx; Type: INDEX; Schema: generated_stored_tests; Owner: ashutoshpg
--

CREATE INDEX gtest22c_expr_idx ON generated_stored_tests.gtest22c USING btree (((b * 3)));


--
-- Name: gtest22c_pred_idx; Type: INDEX; Schema: generated_stored_tests; Owner: ashutoshpg
--

CREATE INDEX gtest22c_pred_idx ON generated_stored_tests.gtest22c USING btree (a) WHERE (b > 0);


--
-- Name: alter_idx_rename_test_parted_idx_3; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX alter_idx_rename_test_parted_idx_3 ON ONLY public.alter_idx_rename_test_parted_2 USING btree (a);


--
-- Name: botharrayidx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX botharrayidx ON public.array_index_op_test USING gin (i, t);


--
-- Name: brin_summarize_bloom_idx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX brin_summarize_bloom_idx ON public.brin_summarize_bloom USING brin (value) WITH (pages_per_range='2');


--
-- Name: brin_summarize_idx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX brin_summarize_idx ON public.brin_summarize USING brin (value) WITH (pages_per_range='2');


--
-- Name: brin_summarize_multi_idx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX brin_summarize_multi_idx ON public.brin_summarize_multi USING brin (value) WITH (pages_per_range='2');


--
-- Name: brin_test_a_idx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX brin_test_a_idx ON public.brin_test USING brin (a) WITH (pages_per_range='2');


--
-- Name: brin_test_b_idx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX brin_test_b_idx ON public.brin_test USING brin (b) WITH (pages_per_range='2');


--
-- Name: brin_test_bloom_a_idx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX brin_test_bloom_a_idx ON public.brin_test_bloom USING brin (a) WITH (pages_per_range='2');


--
-- Name: brin_test_bloom_b_idx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX brin_test_bloom_b_idx ON public.brin_test_bloom USING brin (b) WITH (pages_per_range='2');


--
-- Name: brin_test_multi_a_idx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX brin_test_multi_a_idx ON public.brin_test_multi USING brin (a) WITH (pages_per_range='2');


--
-- Name: brin_test_multi_b_idx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX brin_test_multi_b_idx ON public.brin_test_multi USING brin (b) WITH (pages_per_range='2');


--
-- Name: brinidx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX brinidx ON public.brintest USING brin (byteacol, charcol, namecol, int8col, int2col, int4col, textcol, oidcol, tidcol, float4col, float8col, macaddrcol, inetcol, inetcol inet_minmax_ops, cidrcol, cidrcol inet_minmax_ops, bpcharcol, datecol, timecol, timestampcol, timestamptzcol, intervalcol, timetzcol, bitcol, varbitcol, numericcol, uuidcol, int4rangecol, lsncol, boxcol) WITH (pages_per_range='1');


--
-- Name: brinidx_bloom; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX brinidx_bloom ON public.brintest_bloom USING brin (byteacol bytea_bloom_ops, charcol char_bloom_ops, namecol name_bloom_ops, int8col int8_bloom_ops, int2col int2_bloom_ops, int4col int4_bloom_ops, textcol text_bloom_ops, oidcol oid_bloom_ops, float4col float4_bloom_ops, float8col float8_bloom_ops, macaddrcol macaddr_bloom_ops, inetcol inet_bloom_ops, cidrcol inet_bloom_ops, bpcharcol bpchar_bloom_ops, datecol date_bloom_ops, timecol time_bloom_ops, timestampcol timestamp_bloom_ops, timestamptzcol timestamptz_bloom_ops, intervalcol interval_bloom_ops, timetzcol timetz_bloom_ops, numericcol numeric_bloom_ops, uuidcol uuid_bloom_ops, lsncol pg_lsn_bloom_ops) WITH (pages_per_range='1');


--
-- Name: brinidx_multi; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX brinidx_multi ON public.brintest_multi USING brin (int8col int8_minmax_multi_ops, int2col int2_minmax_multi_ops, int4col int4_minmax_multi_ops, oidcol oid_minmax_multi_ops, tidcol tid_minmax_multi_ops, float4col float4_minmax_multi_ops, float8col float8_minmax_multi_ops, macaddrcol macaddr_minmax_multi_ops, macaddr8col macaddr8_minmax_multi_ops, inetcol inet_minmax_multi_ops, cidrcol inet_minmax_multi_ops, datecol date_minmax_multi_ops, timecol time_minmax_multi_ops, timestampcol timestamp_minmax_multi_ops, timestamptzcol timestamptz_minmax_multi_ops, intervalcol interval_minmax_multi_ops, timetzcol timetz_minmax_multi_ops, numericcol numeric_minmax_multi_ops, uuidcol uuid_minmax_multi_ops, lsncol pg_lsn_minmax_multi_ops) WITH (pages_per_range='1');


--
-- Name: bt_f8_index; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX bt_f8_index ON public.bt_f8_heap USING btree (seqno);


--
-- Name: bt_i4_index; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX bt_i4_index ON public.bt_i4_heap USING btree (seqno);


--
-- Name: bt_name_index; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX bt_name_index ON public.bt_name_heap USING btree (seqno);


--
-- Name: bt_tsq; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE UNIQUE INDEX bt_tsq ON public.test_tsquery USING btree (keyword);


--
-- Name: bt_txt_index; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX bt_txt_index ON public.bt_txt_heap USING btree (seqno);


--
-- Name: btree_tall_idx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX btree_tall_idx ON public.btree_tall_tbl USING btree (t, id) WITH (fillfactor='10');


--
-- Name: clstr_tst_b; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX clstr_tst_b ON public.clstr_tst USING btree (b);


--
-- Name: clstr_tst_b_c; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX clstr_tst_b_c ON public.clstr_tst USING btree (b, c);


--
-- Name: clstr_tst_c; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX clstr_tst_c ON public.clstr_tst USING btree (c);


--
-- Name: clstr_tst_c_b; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX clstr_tst_c_b ON public.clstr_tst USING btree (c, b);


--
-- Name: comment_test_child_fk; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX comment_test_child_fk ON public.comment_test_child USING btree (id);


--
-- Name: INDEX comment_test_child_fk; Type: COMMENT; Schema: public; Owner: ashutoshpg
--

COMMENT ON INDEX public.comment_test_child_fk IS 'Index backing the FOREIGN KEY of comment_test_child';


--
-- Name: comment_test_index; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX comment_test_index ON public.comment_test USING btree (indexed_col);


--
-- Name: INDEX comment_test_index; Type: COMMENT; Schema: public; Owner: ashutoshpg
--

COMMENT ON INDEX public.comment_test_index IS 'Simple index on comment_test';


--
-- Name: INDEX comment_test_pk; Type: COMMENT; Schema: public; Owner: ashutoshpg
--

COMMENT ON INDEX public.comment_test_pk IS 'Index backing the PRIMARY KEY of comment_test';


--
-- Name: covidxpart_a_b_idx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE UNIQUE INDEX covidxpart_a_b_idx ON ONLY public.covidxpart USING btree (a) INCLUDE (b);


--
-- Name: covidxpart1_a_b_idx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE UNIQUE INDEX covidxpart1_a_b_idx ON public.covidxpart1 USING btree (a) INCLUDE (b);


--
-- Name: covidxpart2_a_b_idx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE UNIQUE INDEX covidxpart2_a_b_idx ON public.covidxpart2 USING btree (a) INCLUDE (b);


--
-- Name: covidxpart3_a_b_idx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE UNIQUE INDEX covidxpart3_a_b_idx ON public.covidxpart3 USING btree (a) INCLUDE (b);


--
-- Name: covidxpart4_a_b_idx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE UNIQUE INDEX covidxpart4_a_b_idx ON public.covidxpart4 USING btree (a) INCLUDE (b);


--
-- Name: covidxpart4_a_idx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE UNIQUE INDEX covidxpart4_a_idx ON public.covidxpart4 USING btree (a);


--
-- Name: dedup_unique; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE UNIQUE INDEX dedup_unique ON public.dedup_unique_test_table USING btree (a) WITH (deduplicate_items='on');


--
-- Name: dupindexcols_i; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX dupindexcols_i ON public.dupindexcols USING btree (f1, id, f1 text_pattern_ops);


--
-- Name: ec1_expr1; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE UNIQUE INDEX ec1_expr1 ON public.ec1 USING btree (((ff + 1)));


--
-- Name: ec1_expr2; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE UNIQUE INDEX ec1_expr2 ON public.ec1 USING btree ((((ff + 2) + 1)));


--
-- Name: ec1_expr4; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE UNIQUE INDEX ec1_expr4 ON public.ec1 USING btree (((ff + 4)));


--
-- Name: fdeps_ab_idx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX fdeps_ab_idx ON public.functional_dependencies USING btree (a, b);


--
-- Name: fdeps_abc_idx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX fdeps_abc_idx ON public.functional_dependencies USING btree (a, b, c);


--
-- Name: func_index_index; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE UNIQUE INDEX func_index_index ON public.func_index_heap USING btree (((f1 || f2)));


--
-- Name: gcircleind; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX gcircleind ON public.circle_tbl USING gist (f1);


--
-- Name: gin_relopts_test; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX gin_relopts_test ON public.array_index_op_test USING gin (i) WITH (fastupdate='on', gin_pending_list_limit='128');


--
-- Name: gin_test_idx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX gin_test_idx ON public.gin_test_tbl USING gin (i) WITH (gin_pending_list_limit='4096', fastupdate=off);


--
-- Name: gist_pointidx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX gist_pointidx ON public.gist_point_tbl USING gist (p) WITH (fillfactor='40');


--
-- Name: gpolygonind; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX gpolygonind ON public.polygon_tbl USING gist (f1);


--
-- Name: grect2ind; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX grect2ind ON public.fast_emp4000 USING gist (home_base);


--
-- Name: hash_f8_index; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX hash_f8_index ON public.hash_f8_heap USING hash (random) WITH (fillfactor='60');


--
-- Name: hash_f8_index_1; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE UNIQUE INDEX hash_f8_index_1 ON public.hash_f8_heap USING btree (abs(random));


--
-- Name: hash_f8_index_2; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE UNIQUE INDEX hash_f8_index_2 ON public.hash_f8_heap USING btree (((seqno + 1)), random);


--
-- Name: hash_f8_index_3; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE UNIQUE INDEX hash_f8_index_3 ON public.hash_f8_heap USING btree (random) WHERE (seqno > 1000);


--
-- Name: hash_i4_index; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX hash_i4_index ON public.hash_i4_heap USING hash (random);


--
-- Name: hash_name_index; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX hash_name_index ON public.hash_name_heap USING hash (random);


--
-- Name: hash_txt_index; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX hash_txt_index ON public.hash_txt_heap USING hash (random);


--
-- Name: hslot_hubname; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX hslot_hubname ON public.hslot USING btree (hubname);


--
-- Name: hslot_name; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE UNIQUE INDEX hslot_name ON public.hslot USING btree (slotname);


--
-- Name: hub_name; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE UNIQUE INDEX hub_name ON public.hub USING btree (name);


--
-- Name: idx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX idx ON public.cmdata USING btree (f1);


--
-- Name: idx1; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE UNIQUE INDEX idx1 ON public.cmdata2 USING btree (((f1 || f2)));


--
-- Name: idxpart_a_idx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX idxpart_a_idx ON ONLY public.idxpart USING btree (a);


--
-- Name: idxpart1_a_idx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX idxpart1_a_idx ON public.idxpart1 USING btree (a);


--
-- Name: idxpart2_a_idx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX idxpart2_a_idx ON ONLY public.idxpart2 USING btree (a);


--
-- Name: idxpart22_a_idx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX idxpart22_a_idx ON public.idxpart22 USING btree (a);


--
-- Name: idxpart3_a_idx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX idxpart3_a_idx ON ONLY public.idxpart3 USING btree (a);


--
-- Name: idxpart31_a_idx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX idxpart31_a_idx ON public.idxpart31 USING btree (a);


--
-- Name: idxpart32_a_idx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX idxpart32_a_idx ON public.idxpart32 USING btree (a);


--
-- Name: iface_name; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE UNIQUE INDEX iface_name ON public.iface USING btree (slotname);


--
-- Name: iix; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX iix ON public.ihighway USING btree (name);


--
-- Name: iprt1_e_p1_ab2; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX iprt1_e_p1_ab2 ON public.prt1_e_p1 USING btree ((((a + b) / 2)));


--
-- Name: iprt1_e_p2_ab2; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX iprt1_e_p2_ab2 ON public.prt1_e_p2 USING btree ((((a + b) / 2)));


--
-- Name: iprt1_e_p3_ab2; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX iprt1_e_p3_ab2 ON public.prt1_e_p3 USING btree ((((a + b) / 2)));


--
-- Name: iprt1_p1_a; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX iprt1_p1_a ON public.prt1_p1 USING btree (a);


--
-- Name: iprt1_p2_a; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX iprt1_p2_a ON public.prt1_p2 USING btree (a);


--
-- Name: iprt1_p3_a; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX iprt1_p3_a ON public.prt1_p3 USING btree (a);


--
-- Name: iprt2_p1_b; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX iprt2_p1_b ON public.prt2_p1 USING btree (b);


--
-- Name: iprt2_p2_b; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX iprt2_p2_b ON public.prt2_p2 USING btree (b);


--
-- Name: iprt2_p3_b; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX iprt2_p3_b ON public.prt2_p3 USING btree (b);


--
-- Name: mvtest_aa; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX mvtest_aa ON public.mvtest_bb USING btree (grandtot);


--
-- Name: mvtest_tm_type; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE UNIQUE INDEX mvtest_tm_type ON public.mvtest_tm USING btree (type);


--
-- Name: mvtest_tvmm_expr; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE UNIQUE INDEX mvtest_tvmm_expr ON public.mvtest_tvmm USING btree (((grandtot > (0)::numeric)));


--
-- Name: mvtest_tvmm_pred; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE UNIQUE INDEX mvtest_tvmm_pred ON public.mvtest_tvmm USING btree (grandtot) WHERE (grandtot < (0)::numeric);


--
-- Name: num_exp_add_idx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE UNIQUE INDEX num_exp_add_idx ON public.num_exp_add USING btree (id1, id2);


--
-- Name: num_exp_div_idx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE UNIQUE INDEX num_exp_div_idx ON public.num_exp_div USING btree (id1, id2);


--
-- Name: num_exp_ln_idx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE UNIQUE INDEX num_exp_ln_idx ON public.num_exp_ln USING btree (id);


--
-- Name: num_exp_log10_idx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE UNIQUE INDEX num_exp_log10_idx ON public.num_exp_log10 USING btree (id);


--
-- Name: num_exp_mul_idx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE UNIQUE INDEX num_exp_mul_idx ON public.num_exp_mul USING btree (id1, id2);


--
-- Name: num_exp_power_10_ln_idx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE UNIQUE INDEX num_exp_power_10_ln_idx ON public.num_exp_power_10_ln USING btree (id);


--
-- Name: num_exp_sqrt_idx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE UNIQUE INDEX num_exp_sqrt_idx ON public.num_exp_sqrt USING btree (id);


--
-- Name: num_exp_sub_idx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE UNIQUE INDEX num_exp_sub_idx ON public.num_exp_sub USING btree (id1, id2);


--
-- Name: nummultirange_test_btree; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX nummultirange_test_btree ON public.nummultirange_test USING btree (nmr);


--
-- Name: numrange_test_btree; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX numrange_test_btree ON public.numrange_test USING btree (nr);


--
-- Name: onek2_stu1_prtl; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX onek2_stu1_prtl ON public.onek2 USING btree (stringu1) WHERE ((stringu1 >= 'J'::name) AND (stringu1 < 'K'::name));


--
-- Name: onek2_u1_prtl; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX onek2_u1_prtl ON public.onek2 USING btree (unique1) WHERE ((unique1 < 20) OR (unique1 > 980));


--
-- Name: onek2_u2_prtl; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX onek2_u2_prtl ON public.onek2 USING btree (unique2) WHERE (stringu1 < 'B'::name);


--
-- Name: onek_hundred; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX onek_hundred ON public.onek USING btree (hundred);


--
-- Name: onek_stringu1; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX onek_stringu1 ON public.onek USING btree (stringu1);


--
-- Name: onek_unique1; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX onek_unique1 ON public.onek USING btree (unique1);


--
-- Name: onek_unique2; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX onek_unique2 ON public.onek USING btree (unique2);


--
-- Name: pfield_name; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE UNIQUE INDEX pfield_name ON public.pfield USING btree (name);


--
-- Name: phone_name; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE UNIQUE INDEX phone_name ON public.phone USING btree (slotname);


--
-- Name: pline_name; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE UNIQUE INDEX pline_name ON public.pline USING btree (slotname);


--
-- Name: point_table_a_idx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX point_table_a_idx ON public.point_table USING gist (a);


--
-- Name: pslot_name; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE UNIQUE INDEX pslot_name ON public.pslot USING btree (slotname);


--
-- Name: qq; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX qq ON public.test_tsquery USING gist (keyword);


--
-- Name: quad_box_tbl_idx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX quad_box_tbl_idx ON public.quad_box_tbl USING spgist (b);


--
-- Name: quad_poly_tbl_idx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX quad_poly_tbl_idx ON public.quad_poly_tbl USING spgist (p);


--
-- Name: regress_constr_partitioned_a_idx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE UNIQUE INDEX regress_constr_partitioned_a_idx ON ONLY public.regress_constr_partitioned USING btree (a);


--
-- Name: regular_sized_index; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX regular_sized_index ON public.parallel_vacuum_table USING btree (a);


--
-- Name: reloptions_test_idx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX reloptions_test_idx ON public.reloptions_test USING btree (s) WITH (fillfactor='40');


--
-- Name: reloptions_test_idx3; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX reloptions_test_idx3 ON public.reloptions_test USING btree (s) WITH (fillfactor='40');


--
-- Name: rix; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX rix ON public.road USING btree (name);


--
-- Name: room_rno; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE UNIQUE INDEX room_rno ON public.room USING btree (roomno);


--
-- Name: six; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX six ON public.shighway USING btree (name);


--
-- Name: sp_kd_ind; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX sp_kd_ind ON public.kd_point_tbl USING spgist (p kd_point_ops);


--
-- Name: sp_quad_ind; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX sp_quad_ind ON public.quad_point_tbl USING spgist (p);


--
-- Name: sp_radix_ind; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX sp_radix_ind ON public.radix_text_tbl USING spgist (t);


--
-- Name: spgist_box_idx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX spgist_box_idx ON public.spgist_box_tbl USING spgist (b);


--
-- Name: spgist_domain_idx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX spgist_domain_idx ON public.spgist_domain_tbl USING spgist (f1);


--
-- Name: spgist_point_idx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX spgist_point_idx ON public.spgist_point_tbl USING spgist (p) WITH (fillfactor='90');


--
-- Name: spgist_text_idx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX spgist_text_idx ON public.spgist_text_tbl USING spgist (t);


--
-- Name: spgist_unlogged_idx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX spgist_unlogged_idx ON public.spgist_unlogged_tbl USING spgist (b);


--
-- Name: stats_test_idx1; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX stats_test_idx1 ON public.stats_test_tab1 USING btree (a);


--
-- Name: system_name; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE UNIQUE INDEX system_name ON public.system USING btree (name);


--
-- Name: tbl_include_reg_c1_c2_c11_c3_idx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX tbl_include_reg_c1_c2_c11_c3_idx ON public.tbl_include_reg USING btree (c1, c2) INCLUDE (c1, c3);


--
-- Name: tbl_include_reg_idx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX tbl_include_reg_idx ON public.tbl_include_reg USING btree (c1, c2) INCLUDE (c3, c4);


--
-- Name: tenk1_hundred; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX tenk1_hundred ON public.tenk1 USING btree (hundred);


--
-- Name: tenk1_thous_tenthous; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX tenk1_thous_tenthous ON public.tenk1 USING btree (thousand, tenthous);


--
-- Name: tenk1_unique1; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX tenk1_unique1 ON public.tenk1 USING btree (unique1);


--
-- Name: tenk1_unique2; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX tenk1_unique2 ON public.tenk1 USING btree (unique2);


--
-- Name: tenk2_hundred; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX tenk2_hundred ON public.tenk2 USING btree (hundred);


--
-- Name: tenk2_unique1; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX tenk2_unique1 ON public.tenk2 USING btree (unique1);


--
-- Name: tenk2_unique2; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX tenk2_unique2 ON public.tenk2 USING btree (unique2);


--
-- Name: test_range_gist_idx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX test_range_gist_idx ON public.test_range_gist USING gist (ir);


--
-- Name: test_range_spgist_idx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX test_range_spgist_idx ON public.test_range_spgist USING spgist (ir);


--
-- Name: test_storage_idx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX test_storage_idx ON public.test_storage USING btree (b, a);


--
-- Name: textrange_test_btree; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX textrange_test_btree ON public.textrange_test USING btree (tr);


--
-- Name: typically_sized_index; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX typically_sized_index ON public.parallel_vacuum_table USING btree (a);


--
-- Name: vacuum_in_leader_small_index; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX vacuum_in_leader_small_index ON public.parallel_vacuum_table USING btree ((1));


--
-- Name: wowidx; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE INDEX wowidx ON public.test_tsvector USING gin (a);


--
-- Name: wslot_name; Type: INDEX; Schema: public; Owner: ashutoshpg
--

CREATE UNIQUE INDEX wslot_name ON public.wslot USING btree (slotname);


--
-- Name: pk1_pkey; Type: INDEX ATTACH; Schema: fkpart3; Owner: ashutoshpg
--

ALTER INDEX fkpart3.pk_pkey ATTACH PARTITION fkpart3.pk1_pkey;


--
-- Name: pk2_pkey; Type: INDEX ATTACH; Schema: fkpart3; Owner: ashutoshpg
--

ALTER INDEX fkpart3.pk_pkey ATTACH PARTITION fkpart3.pk2_pkey;


--
-- Name: pk3_pkey; Type: INDEX ATTACH; Schema: fkpart3; Owner: ashutoshpg
--

ALTER INDEX fkpart3.pk_pkey ATTACH PARTITION fkpart3.pk3_pkey;


--
-- Name: pk4_pkey; Type: INDEX ATTACH; Schema: fkpart3; Owner: ashutoshpg
--

ALTER INDEX fkpart3.pk_pkey ATTACH PARTITION fkpart3.pk4_pkey;


--
-- Name: pk51_pkey; Type: INDEX ATTACH; Schema: fkpart3; Owner: ashutoshpg
--

ALTER INDEX fkpart3.pk5_pkey ATTACH PARTITION fkpart3.pk51_pkey;


--
-- Name: pk52_pkey; Type: INDEX ATTACH; Schema: fkpart3; Owner: ashutoshpg
--

ALTER INDEX fkpart3.pk5_pkey ATTACH PARTITION fkpart3.pk52_pkey;


--
-- Name: pk5_pkey; Type: INDEX ATTACH; Schema: fkpart3; Owner: ashutoshpg
--

ALTER INDEX fkpart3.pk_pkey ATTACH PARTITION fkpart3.pk5_pkey;


--
-- Name: droppk1_pkey; Type: INDEX ATTACH; Schema: fkpart4; Owner: ashutoshpg
--

ALTER INDEX fkpart4.droppk_pkey ATTACH PARTITION fkpart4.droppk1_pkey;


--
-- Name: droppk2_d_pkey; Type: INDEX ATTACH; Schema: fkpart4; Owner: ashutoshpg
--

ALTER INDEX fkpart4.droppk2_pkey ATTACH PARTITION fkpart4.droppk2_d_pkey;


--
-- Name: droppk2_pkey; Type: INDEX ATTACH; Schema: fkpart4; Owner: ashutoshpg
--

ALTER INDEX fkpart4.droppk_pkey ATTACH PARTITION fkpart4.droppk2_pkey;


--
-- Name: droppk_d_pkey; Type: INDEX ATTACH; Schema: fkpart4; Owner: ashutoshpg
--

ALTER INDEX fkpart4.droppk_pkey ATTACH PARTITION fkpart4.droppk_d_pkey;


--
-- Name: pk11_pkey; Type: INDEX ATTACH; Schema: fkpart5; Owner: ashutoshpg
--

ALTER INDEX fkpart5.pk1_pkey ATTACH PARTITION fkpart5.pk11_pkey;


--
-- Name: pk1_pkey; Type: INDEX ATTACH; Schema: fkpart5; Owner: ashutoshpg
--

ALTER INDEX fkpart5.pk_pkey ATTACH PARTITION fkpart5.pk1_pkey;


--
-- Name: pk2_pkey; Type: INDEX ATTACH; Schema: fkpart5; Owner: ashutoshpg
--

ALTER INDEX fkpart5.pk_pkey ATTACH PARTITION fkpart5.pk2_pkey;


--
-- Name: pk31_pkey; Type: INDEX ATTACH; Schema: fkpart5; Owner: ashutoshpg
--

ALTER INDEX fkpart5.pk3_pkey ATTACH PARTITION fkpart5.pk31_pkey;


--
-- Name: pk32_pkey; Type: INDEX ATTACH; Schema: fkpart5; Owner: ashutoshpg
--

ALTER INDEX fkpart5.pk3_pkey ATTACH PARTITION fkpart5.pk32_pkey;


--
-- Name: pk3_pkey; Type: INDEX ATTACH; Schema: fkpart5; Owner: ashutoshpg
--

ALTER INDEX fkpart5.pk_pkey ATTACH PARTITION fkpart5.pk3_pkey;


--
-- Name: pk11_pkey; Type: INDEX ATTACH; Schema: fkpart6; Owner: ashutoshpg
--

ALTER INDEX fkpart6.pk1_pkey ATTACH PARTITION fkpart6.pk11_pkey;


--
-- Name: pk12_pkey; Type: INDEX ATTACH; Schema: fkpart6; Owner: ashutoshpg
--

ALTER INDEX fkpart6.pk1_pkey ATTACH PARTITION fkpart6.pk12_pkey;


--
-- Name: pk1_pkey; Type: INDEX ATTACH; Schema: fkpart6; Owner: ashutoshpg
--

ALTER INDEX fkpart6.pk_pkey ATTACH PARTITION fkpart6.pk1_pkey;


--
-- Name: covidxpart1_a_b_idx; Type: INDEX ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER INDEX public.covidxpart_a_b_idx ATTACH PARTITION public.covidxpart1_a_b_idx;


--
-- Name: covidxpart2_a_b_idx; Type: INDEX ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER INDEX public.covidxpart_a_b_idx ATTACH PARTITION public.covidxpart2_a_b_idx;


--
-- Name: covidxpart3_a_b_idx; Type: INDEX ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER INDEX public.covidxpart_a_b_idx ATTACH PARTITION public.covidxpart3_a_b_idx;


--
-- Name: covidxpart4_a_b_idx; Type: INDEX ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER INDEX public.covidxpart_a_b_idx ATTACH PARTITION public.covidxpart4_a_b_idx;


--
-- Name: idxpart1_a_idx; Type: INDEX ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER INDEX public.idxpart_a_idx ATTACH PARTITION public.idxpart1_a_idx;


--
-- Name: idxpart22_a_idx; Type: INDEX ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER INDEX public.idxpart2_a_idx ATTACH PARTITION public.idxpart22_a_idx;


--
-- Name: idxpart2_a_idx; Type: INDEX ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER INDEX public.idxpart_a_idx ATTACH PARTITION public.idxpart2_a_idx;


--
-- Name: idxpart31_a_idx; Type: INDEX ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER INDEX public.idxpart3_a_idx ATTACH PARTITION public.idxpart31_a_idx;


--
-- Name: idxpart32_a_idx; Type: INDEX ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER INDEX public.idxpart3_a_idx ATTACH PARTITION public.idxpart32_a_idx;


--
-- Name: idxpart3_a_idx; Type: INDEX ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER INDEX public.idxpart_a_idx ATTACH PARTITION public.idxpart3_a_idx;


--
-- Name: idxpart_another_1_pkey; Type: INDEX ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER INDEX public.idxpart_another_pkey ATTACH PARTITION public.idxpart_another_1_pkey;


--
-- Name: part1_self_fk_pkey; Type: INDEX ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER INDEX public.parted_self_fk_pkey ATTACH PARTITION public.part1_self_fk_pkey;


--
-- Name: part2_self_fk_pkey; Type: INDEX ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER INDEX public.parted_self_fk_pkey ATTACH PARTITION public.part2_self_fk_pkey;


--
-- Name: part32_self_fk_pkey; Type: INDEX ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER INDEX public.part3_self_fk_pkey ATTACH PARTITION public.part32_self_fk_pkey;


--
-- Name: part33_self_fk_pkey; Type: INDEX ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER INDEX public.part3_self_fk_pkey ATTACH PARTITION public.part33_self_fk_pkey;


--
-- Name: part3_self_fk_pkey; Type: INDEX ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER INDEX public.parted_self_fk_pkey ATTACH PARTITION public.part3_self_fk_pkey;


--
-- Name: regress_constr_partition1_pkey; Type: INDEX ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER INDEX public.regress_constr_partitioned_a_idx ATTACH PARTITION public.regress_constr_partition1_pkey;


--
-- Name: trigger_parted_p1_1_pkey; Type: INDEX ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER INDEX public.trigger_parted_p1_pkey ATTACH PARTITION public.trigger_parted_p1_1_pkey;


--
-- Name: trigger_parted_p1_pkey; Type: INDEX ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER INDEX public.trigger_parted_pkey ATTACH PARTITION public.trigger_parted_p1_pkey;


--
-- Name: trigger_parted_p2_2_pkey; Type: INDEX ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER INDEX public.trigger_parted_p2_pkey ATTACH PARTITION public.trigger_parted_p2_2_pkey;


--
-- Name: trigger_parted_p2_pkey; Type: INDEX ATTACH; Schema: public; Owner: ashutoshpg
--

ALTER INDEX public.trigger_parted_pkey ATTACH PARTITION public.trigger_parted_p2_pkey;


--
-- Name: pk1_pkey; Type: INDEX ATTACH; Schema: regress_indexing; Owner: ashutoshpg
--

ALTER INDEX regress_indexing.pk_pkey ATTACH PARTITION regress_indexing.pk1_pkey;


--
-- Name: pk2_pkey; Type: INDEX ATTACH; Schema: regress_indexing; Owner: ashutoshpg
--

ALTER INDEX regress_indexing.pk_pkey ATTACH PARTITION regress_indexing.pk2_pkey;


--
-- Name: pk3_pkey; Type: INDEX ATTACH; Schema: regress_indexing; Owner: ashutoshpg
--

ALTER INDEX regress_indexing.pk_pkey ATTACH PARTITION regress_indexing.pk3_pkey;


--
-- Name: pk4_pkey; Type: INDEX ATTACH; Schema: regress_indexing; Owner: ashutoshpg
--

ALTER INDEX regress_indexing.pk_pkey ATTACH PARTITION regress_indexing.pk4_pkey;


--
-- Name: pk51_pkey; Type: INDEX ATTACH; Schema: regress_indexing; Owner: ashutoshpg
--

ALTER INDEX regress_indexing.pk5_pkey ATTACH PARTITION regress_indexing.pk51_pkey;


--
-- Name: pk52_pkey; Type: INDEX ATTACH; Schema: regress_indexing; Owner: ashutoshpg
--

ALTER INDEX regress_indexing.pk5_pkey ATTACH PARTITION regress_indexing.pk52_pkey;


--
-- Name: pk5_pkey; Type: INDEX ATTACH; Schema: regress_indexing; Owner: ashutoshpg
--

ALTER INDEX regress_indexing.pk_pkey ATTACH PARTITION regress_indexing.pk5_pkey;


--
-- Name: func_deps_stat; Type: STATISTICS; Schema: public; Owner: ashutoshpg
--

CREATE STATISTICS public.func_deps_stat (dependencies) ON (a * 2), upper(b), (c + 1::numeric) FROM public.functional_dependencies;


ALTER STATISTICS public.func_deps_stat OWNER TO ashutoshpg;

--
-- Name: mcv_lists_arrays_stats; Type: STATISTICS; Schema: public; Owner: ashutoshpg
--

CREATE STATISTICS public.mcv_lists_arrays_stats (mcv) ON a, b, c FROM public.mcv_lists_arrays;


ALTER STATISTICS public.mcv_lists_arrays_stats OWNER TO ashutoshpg;

--
-- Name: mcv_lists_bool_stats; Type: STATISTICS; Schema: public; Owner: ashutoshpg
--

CREATE STATISTICS public.mcv_lists_bool_stats (mcv) ON a, b, c FROM public.mcv_lists_bool;


ALTER STATISTICS public.mcv_lists_bool_stats OWNER TO ashutoshpg;

--
-- Name: mcv_lists_stats; Type: STATISTICS; Schema: public; Owner: ashutoshpg
--

CREATE STATISTICS public.mcv_lists_stats (mcv) ON a, b, d FROM public.mcv_lists;


ALTER STATISTICS public.mcv_lists_stats OWNER TO ashutoshpg;

--
-- Name: key_dependent_view _RETURN; Type: RULE; Schema: public; Owner: ashutoshpg
--

CREATE OR REPLACE VIEW public.key_dependent_view AS
 SELECT key,
    data
   FROM public.view_base_table
  GROUP BY key;


--
-- Name: key_dependent_view_no_cols _RETURN; Type: RULE; Schema: public; Owner: ashutoshpg
--

CREATE OR REPLACE VIEW public.key_dependent_view_no_cols AS
 SELECT
   FROM public.view_base_table
  GROUP BY key
 HAVING (length((data)::text) > 0);


--
-- Name: shoelace_data log_shoelace; Type: RULE; Schema: public; Owner: ashutoshpg
--

CREATE RULE log_shoelace AS
    ON UPDATE TO public.shoelace_data
   WHERE (new.sl_avail <> old.sl_avail) DO  INSERT INTO public.shoelace_log (sl_name, sl_avail, log_who, log_when)
  VALUES (new.sl_name, new.sl_avail, 'Al Bundy'::name, '1970-01-01 00:00:00'::timestamp without time zone);


--
-- Name: ruletest_tbl myrule; Type: RULE; Schema: public; Owner: ashutoshpg
--

CREATE RULE myrule AS
    ON INSERT TO public.ruletest_tbl DO INSTEAD  INSERT INTO public.ruletest_tbl2 (a, b)
  VALUES (1000, 1000);


--
-- Name: rules_src r1; Type: RULE; Schema: public; Owner: ashutoshpg
--

CREATE RULE r1 AS
    ON UPDATE TO public.rules_src DO  INSERT INTO public.rules_log (f1, f2, tag, id) VALUES (old.f1,old.f2,'old'::text,DEFAULT), (new.f1,new.f2,'new'::text,DEFAULT);


--
-- Name: rules_src r2; Type: RULE; Schema: public; Owner: ashutoshpg
--

CREATE RULE r2 AS
    ON UPDATE TO public.rules_src DO  VALUES (old.f1,old.f2,'old'::text), (new.f1,new.f2,'new'::text);


--
-- Name: rules_src r3; Type: RULE; Schema: public; Owner: ashutoshpg
--

CREATE RULE r3 AS
    ON INSERT TO public.rules_src DO  INSERT INTO public.rules_log (f1, f2, tag, id) VALUES (NULL::integer,NULL::integer,'-'::text,DEFAULT), (new.f1,new.f2,'new'::text,DEFAULT);


--
-- Name: rules_src r4; Type: RULE; Schema: public; Owner: ashutoshpg
--

CREATE RULE r4 AS
    ON DELETE TO public.rules_src DO
 NOTIFY rules_src_deletion;


--
-- Name: rules_src r5; Type: RULE; Schema: public; Owner: ashutoshpg
--

CREATE RULE r5 AS
    ON INSERT TO public.rules_src DO INSTEAD  INSERT INTO public.rules_log AS trgt (f1, f2)  SELECT new.f1,
            new.f2
  RETURNING trgt.f1,
    trgt.f2;


--
-- Name: rules_src r6; Type: RULE; Schema: public; Owner: ashutoshpg
--

CREATE RULE r6 AS
    ON UPDATE TO public.rules_src DO INSTEAD  UPDATE public.rules_log trgt SET tag = 'updated'::text
  WHERE (trgt.f1 = new.f1);


--
-- Name: rules_src r7; Type: RULE; Schema: public; Owner: ashutoshpg
--

CREATE RULE r7 AS
    ON DELETE TO public.rules_src DO INSTEAD  WITH wins AS (
         INSERT INTO public.int4_tbl AS trgt_1 (f1)
          VALUES (0)
          RETURNING trgt_1.f1
        ), wupd AS (
         UPDATE public.int4_tbl trgt_1 SET f1 = (trgt_1.f1 + 1)
          RETURNING trgt_1.f1
        ), wdel AS (
         DELETE FROM public.int4_tbl trgt_1
          WHERE (trgt_1.f1 = 0)
          RETURNING trgt_1.f1
        )
 INSERT INTO public.rules_log AS trgt (f1, f2)  SELECT old.f1,
            old.f2
           FROM wins,
            wupd,
            wdel
  RETURNING trgt.f1,
    trgt.f2;


--
-- Name: rtest_emp rtest_emp_del; Type: RULE; Schema: public; Owner: ashutoshpg
--

CREATE RULE rtest_emp_del AS
    ON DELETE TO public.rtest_emp DO  INSERT INTO public.rtest_emplog (ename, who, action, newsal, oldsal)
  VALUES (old.ename, CURRENT_USER, 'fired'::bpchar, 0.00, old.salary);


--
-- Name: rtest_emp rtest_emp_ins; Type: RULE; Schema: public; Owner: ashutoshpg
--

CREATE RULE rtest_emp_ins AS
    ON INSERT TO public.rtest_emp DO  INSERT INTO public.rtest_emplog (ename, who, action, newsal, oldsal)
  VALUES (new.ename, CURRENT_USER, 'hired'::bpchar, new.salary, 0.00);


--
-- Name: rtest_emp rtest_emp_upd; Type: RULE; Schema: public; Owner: ashutoshpg
--

CREATE RULE rtest_emp_upd AS
    ON UPDATE TO public.rtest_emp
   WHERE (new.salary <> old.salary) DO  INSERT INTO public.rtest_emplog (ename, who, action, newsal, oldsal)
  VALUES (new.ename, CURRENT_USER, 'honored'::bpchar, new.salary, old.salary);


--
-- Name: rtest_nothn1 rtest_nothn_r1; Type: RULE; Schema: public; Owner: ashutoshpg
--

CREATE RULE rtest_nothn_r1 AS
    ON INSERT TO public.rtest_nothn1
   WHERE ((new.a >= 10) AND (new.a < 20)) DO INSTEAD NOTHING;


--
-- Name: rtest_nothn1 rtest_nothn_r2; Type: RULE; Schema: public; Owner: ashutoshpg
--

CREATE RULE rtest_nothn_r2 AS
    ON INSERT TO public.rtest_nothn1
   WHERE ((new.a >= 30) AND (new.a < 40)) DO INSTEAD NOTHING;


--
-- Name: rtest_nothn2 rtest_nothn_r3; Type: RULE; Schema: public; Owner: ashutoshpg
--

CREATE RULE rtest_nothn_r3 AS
    ON INSERT TO public.rtest_nothn2
   WHERE (new.a >= 100) DO INSTEAD  INSERT INTO public.rtest_nothn3 (a, b)
  VALUES (new.a, new.b);


--
-- Name: rtest_nothn2 rtest_nothn_r4; Type: RULE; Schema: public; Owner: ashutoshpg
--

CREATE RULE rtest_nothn_r4 AS
    ON INSERT TO public.rtest_nothn2 DO INSTEAD NOTHING;


--
-- Name: rtest_order1 rtest_order_r1; Type: RULE; Schema: public; Owner: ashutoshpg
--

CREATE RULE rtest_order_r1 AS
    ON INSERT TO public.rtest_order1 DO INSTEAD  INSERT INTO public.rtest_order2 (a, b, c)
  VALUES (new.a, nextval('public.rtest_seq'::regclass), 'rule 1 - this should run 1st'::text);


--
-- Name: rtest_order1 rtest_order_r2; Type: RULE; Schema: public; Owner: ashutoshpg
--

CREATE RULE rtest_order_r2 AS
    ON INSERT TO public.rtest_order1 DO  INSERT INTO public.rtest_order2 (a, b, c)
  VALUES (new.a, nextval('public.rtest_seq'::regclass), 'rule 2 - this should run 2nd'::text);


--
-- Name: rtest_order1 rtest_order_r3; Type: RULE; Schema: public; Owner: ashutoshpg
--

CREATE RULE rtest_order_r3 AS
    ON INSERT TO public.rtest_order1 DO INSTEAD  INSERT INTO public.rtest_order2 (a, b, c)
  VALUES (new.a, nextval('public.rtest_seq'::regclass), 'rule 3 - this should run 3rd'::text);


--
-- Name: rtest_order1 rtest_order_r4; Type: RULE; Schema: public; Owner: ashutoshpg
--

CREATE RULE rtest_order_r4 AS
    ON INSERT TO public.rtest_order1
   WHERE (new.a < 100) DO INSTEAD  INSERT INTO public.rtest_order2 (a, b, c)
  VALUES (new.a, nextval('public.rtest_seq'::regclass), 'rule 4 - this should run 4th'::text);


--
-- Name: rtest_person rtest_pers_del; Type: RULE; Schema: public; Owner: ashutoshpg
--

CREATE RULE rtest_pers_del AS
    ON DELETE TO public.rtest_person DO  DELETE FROM public.rtest_admin
  WHERE (rtest_admin.pname = old.pname);


--
-- Name: rtest_person rtest_pers_upd; Type: RULE; Schema: public; Owner: ashutoshpg
--

CREATE RULE rtest_pers_upd AS
    ON UPDATE TO public.rtest_person DO  UPDATE public.rtest_admin SET pname = new.pname
  WHERE (rtest_admin.pname = old.pname);


--
-- Name: rtest_system rtest_sys_del; Type: RULE; Schema: public; Owner: ashutoshpg
--

CREATE RULE rtest_sys_del AS
    ON DELETE TO public.rtest_system DO ( DELETE FROM public.rtest_interface
  WHERE (rtest_interface.sysname = old.sysname);
 DELETE FROM public.rtest_admin
  WHERE (rtest_admin.sysname = old.sysname);
);


--
-- Name: rtest_system rtest_sys_upd; Type: RULE; Schema: public; Owner: ashutoshpg
--

CREATE RULE rtest_sys_upd AS
    ON UPDATE TO public.rtest_system DO ( UPDATE public.rtest_interface SET sysname = new.sysname
  WHERE (rtest_interface.sysname = old.sysname);
 UPDATE public.rtest_admin SET sysname = new.sysname
  WHERE (rtest_admin.sysname = old.sysname);
);


--
-- Name: rtest_t4 rtest_t4_ins1; Type: RULE; Schema: public; Owner: ashutoshpg
--

CREATE RULE rtest_t4_ins1 AS
    ON INSERT TO public.rtest_t4
   WHERE ((new.a >= 10) AND (new.a < 20)) DO INSTEAD  INSERT INTO public.rtest_t5 (a, b)
  VALUES (new.a, new.b);


--
-- Name: rtest_t4 rtest_t4_ins2; Type: RULE; Schema: public; Owner: ashutoshpg
--

CREATE RULE rtest_t4_ins2 AS
    ON INSERT TO public.rtest_t4
   WHERE ((new.a >= 20) AND (new.a < 30)) DO  INSERT INTO public.rtest_t6 (a, b)
  VALUES (new.a, new.b);


--
-- Name: rtest_t5 rtest_t5_ins; Type: RULE; Schema: public; Owner: ashutoshpg
--

CREATE RULE rtest_t5_ins AS
    ON INSERT TO public.rtest_t5
   WHERE (new.a > 15) DO  INSERT INTO public.rtest_t7 (a, b)
  VALUES (new.a, new.b);


--
-- Name: rtest_t6 rtest_t6_ins; Type: RULE; Schema: public; Owner: ashutoshpg
--

CREATE RULE rtest_t6_ins AS
    ON INSERT TO public.rtest_t6
   WHERE (new.a > 25) DO INSTEAD  INSERT INTO public.rtest_t8 (a, b)
  VALUES (new.a, new.b);


--
-- Name: rtest_v1 rtest_v1_del; Type: RULE; Schema: public; Owner: ashutoshpg
--

CREATE RULE rtest_v1_del AS
    ON DELETE TO public.rtest_v1 DO INSTEAD  DELETE FROM public.rtest_t1
  WHERE (rtest_t1.a = old.a);


--
-- Name: rtest_v1 rtest_v1_ins; Type: RULE; Schema: public; Owner: ashutoshpg
--

CREATE RULE rtest_v1_ins AS
    ON INSERT TO public.rtest_v1 DO INSTEAD  INSERT INTO public.rtest_t1 (a, b)
  VALUES (new.a, new.b);


--
-- Name: rtest_v1 rtest_v1_upd; Type: RULE; Schema: public; Owner: ashutoshpg
--

CREATE RULE rtest_v1_upd AS
    ON UPDATE TO public.rtest_v1 DO INSTEAD  UPDATE public.rtest_t1 SET a = new.a, b = new.b
  WHERE (rtest_t1.a = old.a);


--
-- Name: rule_merge1 rule1; Type: RULE; Schema: public; Owner: ashutoshpg
--

CREATE RULE rule1 AS
    ON INSERT TO public.rule_merge1 DO INSTEAD  INSERT INTO public.rule_merge2 (a, b)
  VALUES (new.a, new.b);
ALTER TABLE public.rule_merge1 DISABLE RULE rule1;


--
-- Name: rule_merge1 rule2; Type: RULE; Schema: public; Owner: ashutoshpg
--

CREATE RULE rule2 AS
    ON UPDATE TO public.rule_merge1 DO INSTEAD  UPDATE public.rule_merge2 SET a = new.a, b = new.b
  WHERE (rule_merge2.a = old.a);
ALTER TABLE public.rule_merge1 DISABLE RULE rule2;


--
-- Name: rule_merge1 rule3; Type: RULE; Schema: public; Owner: ashutoshpg
--

CREATE RULE rule3 AS
    ON DELETE TO public.rule_merge1 DO INSTEAD  DELETE FROM public.rule_merge2
  WHERE (rule_merge2.a = old.a);
ALTER TABLE public.rule_merge1 DISABLE RULE rule3;


--
-- Name: rule_and_refint_t3 rule_and_refint_t3_ins; Type: RULE; Schema: public; Owner: ashutoshpg
--

CREATE RULE rule_and_refint_t3_ins AS
    ON INSERT TO public.rule_and_refint_t3
   WHERE (EXISTS ( SELECT 1
           FROM public.rule_and_refint_t3 rule_and_refint_t3_1
          WHERE ((rule_and_refint_t3_1.id3a = new.id3a) AND (rule_and_refint_t3_1.id3b = new.id3b) AND (rule_and_refint_t3_1.id3c = new.id3c)))) DO INSTEAD  UPDATE public.rule_and_refint_t3 SET data = new.data
  WHERE ((rule_and_refint_t3.id3a = new.id3a) AND (rule_and_refint_t3.id3b = new.id3b) AND (rule_and_refint_t3.id3c = new.id3c));


--
-- Name: shoelace shoelace_del; Type: RULE; Schema: public; Owner: ashutoshpg
--

CREATE RULE shoelace_del AS
    ON DELETE TO public.shoelace DO INSTEAD  DELETE FROM public.shoelace_data
  WHERE (shoelace_data.sl_name = old.sl_name);


--
-- Name: shoelace shoelace_ins; Type: RULE; Schema: public; Owner: ashutoshpg
--

CREATE RULE shoelace_ins AS
    ON INSERT TO public.shoelace DO INSTEAD  INSERT INTO public.shoelace_data (sl_name, sl_avail, sl_color, sl_len, sl_unit)
  VALUES (new.sl_name, new.sl_avail, new.sl_color, new.sl_len, new.sl_unit);


--
-- Name: shoelace_ok shoelace_ok_ins; Type: RULE; Schema: public; Owner: ashutoshpg
--

CREATE RULE shoelace_ok_ins AS
    ON INSERT TO public.shoelace_ok DO INSTEAD  UPDATE public.shoelace SET sl_avail = (shoelace.sl_avail + new.ok_quant)
  WHERE (shoelace.sl_name = new.ok_name);


--
-- Name: shoelace shoelace_upd; Type: RULE; Schema: public; Owner: ashutoshpg
--

CREATE RULE shoelace_upd AS
    ON UPDATE TO public.shoelace DO INSTEAD  UPDATE public.shoelace_data SET sl_name = new.sl_name, sl_avail = new.sl_avail, sl_color = new.sl_color, sl_len = new.sl_len, sl_unit = new.sl_unit
  WHERE (shoelace_data.sl_name = old.sl_name);


--
-- Name: gtest26 gtest12_01; Type: TRIGGER; Schema: generated_stored_tests; Owner: ashutoshpg
--

CREATE TRIGGER gtest12_01 BEFORE UPDATE ON generated_stored_tests.gtest26 FOR EACH ROW EXECUTE FUNCTION generated_stored_tests.gtest_trigger_func();


--
-- Name: gtest26 gtest12_02; Type: TRIGGER; Schema: generated_stored_tests; Owner: ashutoshpg
--

CREATE TRIGGER gtest12_02 BEFORE UPDATE ON generated_stored_tests.gtest26 FOR EACH ROW EXECUTE FUNCTION generated_stored_tests.gtest_trigger_func4();


--
-- Name: gtest26 gtest12_03; Type: TRIGGER; Schema: generated_stored_tests; Owner: ashutoshpg
--

CREATE TRIGGER gtest12_03 BEFORE UPDATE ON generated_stored_tests.gtest26 FOR EACH ROW EXECUTE FUNCTION generated_stored_tests.gtest_trigger_func();


--
-- Name: gtest26 gtest4; Type: TRIGGER; Schema: generated_stored_tests; Owner: ashutoshpg
--

CREATE TRIGGER gtest4 AFTER INSERT OR UPDATE ON generated_stored_tests.gtest26 FOR EACH ROW WHEN ((new.b < 0)) EXECUTE FUNCTION generated_stored_tests.gtest_trigger_func();


--
-- Name: trigger_parted aft_row; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER aft_row AFTER INSERT OR UPDATE ON public.trigger_parted FOR EACH ROW EXECUTE FUNCTION public.trigger_parted_trigfunc();


--
-- Name: trigger_parted_p2 aft_row; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--


ALTER TABLE public.trigger_parted_p2 DISABLE TRIGGER aft_row;


--
-- Name: trigger_parted_p2_2 aft_row; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--


ALTER TABLE public.trigger_parted_p2_2 ENABLE ALWAYS TRIGGER aft_row;


--
-- Name: main_table after_ins_stmt_trig; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER after_ins_stmt_trig AFTER INSERT ON public.main_table FOR EACH STATEMENT EXECUTE FUNCTION public.trigger_func('after_ins_stmt');


--
-- Name: main_table after_upd_a_b_row_trig; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER after_upd_a_b_row_trig AFTER UPDATE OF a, b ON public.main_table FOR EACH ROW EXECUTE FUNCTION public.trigger_func('after_upd_a_b_row');


--
-- Name: main_table after_upd_b_row_trig; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER after_upd_b_row_trig AFTER UPDATE OF b ON public.main_table FOR EACH ROW EXECUTE FUNCTION public.trigger_func('after_upd_b_row');


--
-- Name: main_table after_upd_b_stmt_trig; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER after_upd_b_stmt_trig AFTER UPDATE OF b ON public.main_table FOR EACH STATEMENT EXECUTE FUNCTION public.trigger_func('after_upd_b_stmt');


--
-- Name: main_table after_upd_stmt_trig; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER after_upd_stmt_trig AFTER UPDATE ON public.main_table FOR EACH STATEMENT EXECUTE FUNCTION public.trigger_func('after_upd_stmt');


--
-- Name: alter_table_under_transition_tables alter_table_under_transition_tables_upd_trigger; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER alter_table_under_transition_tables_upd_trigger AFTER UPDATE ON public.alter_table_under_transition_tables REFERENCING OLD TABLE AS d NEW TABLE AS i FOR EACH STATEMENT EXECUTE FUNCTION public.alter_table_under_transition_tables_upd_func();


--
-- Name: main_table before_ins_stmt_trig; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER before_ins_stmt_trig BEFORE INSERT ON public.main_table FOR EACH STATEMENT EXECUTE FUNCTION public.trigger_func('before_ins_stmt');


--
-- Name: main_table before_upd_a_stmt_trig; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER before_upd_a_stmt_trig BEFORE UPDATE OF a ON public.main_table FOR EACH STATEMENT EXECUTE FUNCTION public.trigger_func('before_upd_a_stmt');


--
-- Name: pline tg_backlink_a; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER tg_backlink_a AFTER INSERT OR DELETE OR UPDATE ON public.pline FOR EACH ROW EXECUTE FUNCTION public.tg_backlink_a('PL');


--
-- Name: pslot tg_backlink_a; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER tg_backlink_a AFTER INSERT OR DELETE OR UPDATE ON public.pslot FOR EACH ROW EXECUTE FUNCTION public.tg_backlink_a('PS');


--
-- Name: wslot tg_backlink_a; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER tg_backlink_a AFTER INSERT OR DELETE OR UPDATE ON public.wslot FOR EACH ROW EXECUTE FUNCTION public.tg_backlink_a('WS');


--
-- Name: pline tg_chkbacklink; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER tg_chkbacklink BEFORE INSERT OR UPDATE ON public.pline FOR EACH ROW EXECUTE FUNCTION public.tg_chkbacklink();


--
-- Name: pslot tg_chkbacklink; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER tg_chkbacklink BEFORE INSERT OR UPDATE ON public.pslot FOR EACH ROW EXECUTE FUNCTION public.tg_chkbacklink();


--
-- Name: wslot tg_chkbacklink; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER tg_chkbacklink BEFORE INSERT OR UPDATE ON public.wslot FOR EACH ROW EXECUTE FUNCTION public.tg_chkbacklink();


--
-- Name: hslot tg_chkslotlink; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER tg_chkslotlink BEFORE INSERT OR UPDATE ON public.hslot FOR EACH ROW EXECUTE FUNCTION public.tg_chkslotlink();


--
-- Name: iface tg_chkslotlink; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER tg_chkslotlink BEFORE INSERT OR UPDATE ON public.iface FOR EACH ROW EXECUTE FUNCTION public.tg_chkslotlink();


--
-- Name: phone tg_chkslotlink; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER tg_chkslotlink BEFORE INSERT OR UPDATE ON public.phone FOR EACH ROW EXECUTE FUNCTION public.tg_chkslotlink();


--
-- Name: pslot tg_chkslotlink; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER tg_chkslotlink BEFORE INSERT OR UPDATE ON public.pslot FOR EACH ROW EXECUTE FUNCTION public.tg_chkslotlink();


--
-- Name: wslot tg_chkslotlink; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER tg_chkslotlink BEFORE INSERT OR UPDATE ON public.wslot FOR EACH ROW EXECUTE FUNCTION public.tg_chkslotlink();


--
-- Name: iface tg_chkslotname; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER tg_chkslotname BEFORE INSERT ON public.iface FOR EACH ROW EXECUTE FUNCTION public.tg_chkslotname('IF');


--
-- Name: phone tg_chkslotname; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER tg_chkslotname BEFORE INSERT ON public.phone FOR EACH ROW EXECUTE FUNCTION public.tg_chkslotname('PH');


--
-- Name: pline tg_chkslotname; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER tg_chkslotname BEFORE INSERT ON public.pline FOR EACH ROW EXECUTE FUNCTION public.tg_chkslotname('PL');


--
-- Name: pslot tg_chkslotname; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER tg_chkslotname BEFORE INSERT ON public.pslot FOR EACH ROW EXECUTE FUNCTION public.tg_chkslotname('PS');


--
-- Name: wslot tg_chkslotname; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER tg_chkslotname BEFORE INSERT ON public.wslot FOR EACH ROW EXECUTE FUNCTION public.tg_chkslotname('WS');


--
-- Name: hslot tg_hslot_bd; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER tg_hslot_bd BEFORE DELETE ON public.hslot FOR EACH ROW EXECUTE FUNCTION public.tg_hslot_bd();


--
-- Name: hslot tg_hslot_biu; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER tg_hslot_biu BEFORE INSERT OR UPDATE ON public.hslot FOR EACH ROW EXECUTE FUNCTION public.tg_hslot_biu();


--
-- Name: hslot tg_hslot_bu; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER tg_hslot_bu BEFORE UPDATE ON public.hslot FOR EACH ROW EXECUTE FUNCTION public.tg_hslot_bu();


--
-- Name: hub tg_hub_a; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER tg_hub_a AFTER INSERT OR DELETE OR UPDATE ON public.hub FOR EACH ROW EXECUTE FUNCTION public.tg_hub_a();


--
-- Name: iface tg_iface_biu; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER tg_iface_biu BEFORE INSERT OR UPDATE ON public.iface FOR EACH ROW EXECUTE FUNCTION public.tg_iface_biu();


--
-- Name: iface tg_iface_bu; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER tg_iface_bu BEFORE UPDATE ON public.iface FOR EACH ROW EXECUTE FUNCTION public.tg_iface_bu();


--
-- Name: pfield tg_pfield_ad; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER tg_pfield_ad AFTER DELETE ON public.pfield FOR EACH ROW EXECUTE FUNCTION public.tg_pfield_ad();


--
-- Name: pfield tg_pfield_au; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER tg_pfield_au AFTER UPDATE ON public.pfield FOR EACH ROW EXECUTE FUNCTION public.tg_pfield_au();


--
-- Name: phone tg_phone_bu; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER tg_phone_bu BEFORE UPDATE ON public.phone FOR EACH ROW EXECUTE FUNCTION public.tg_phone_bu();


--
-- Name: pline tg_pline_bu; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER tg_pline_bu BEFORE UPDATE ON public.pline FOR EACH ROW EXECUTE FUNCTION public.tg_pline_bu();


--
-- Name: pslot tg_pslot_biu; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER tg_pslot_biu BEFORE INSERT OR UPDATE ON public.pslot FOR EACH ROW EXECUTE FUNCTION public.tg_pslot_biu();


--
-- Name: pslot tg_pslot_bu; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER tg_pslot_bu BEFORE UPDATE ON public.pslot FOR EACH ROW EXECUTE FUNCTION public.tg_pslot_bu();


--
-- Name: room tg_room_ad; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER tg_room_ad AFTER DELETE ON public.room FOR EACH ROW EXECUTE FUNCTION public.tg_room_ad();


--
-- Name: room tg_room_au; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER tg_room_au AFTER UPDATE ON public.room FOR EACH ROW EXECUTE FUNCTION public.tg_room_au();


--
-- Name: hslot tg_slotlink_a; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER tg_slotlink_a AFTER INSERT OR DELETE OR UPDATE ON public.hslot FOR EACH ROW EXECUTE FUNCTION public.tg_slotlink_a('HS');


--
-- Name: iface tg_slotlink_a; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER tg_slotlink_a AFTER INSERT OR DELETE OR UPDATE ON public.iface FOR EACH ROW EXECUTE FUNCTION public.tg_slotlink_a('IF');


--
-- Name: phone tg_slotlink_a; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER tg_slotlink_a AFTER INSERT OR DELETE OR UPDATE ON public.phone FOR EACH ROW EXECUTE FUNCTION public.tg_slotlink_a('PH');


--
-- Name: pslot tg_slotlink_a; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER tg_slotlink_a AFTER INSERT OR DELETE OR UPDATE ON public.pslot FOR EACH ROW EXECUTE FUNCTION public.tg_slotlink_a('PS');


--
-- Name: wslot tg_slotlink_a; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER tg_slotlink_a AFTER INSERT OR DELETE OR UPDATE ON public.wslot FOR EACH ROW EXECUTE FUNCTION public.tg_slotlink_a('WS');


--
-- Name: system tg_system_au; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER tg_system_au AFTER UPDATE ON public.system FOR EACH ROW EXECUTE FUNCTION public.tg_system_au();


--
-- Name: wslot tg_wslot_biu; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER tg_wslot_biu BEFORE INSERT OR UPDATE ON public.wslot FOR EACH ROW EXECUTE FUNCTION public.tg_wslot_biu();


--
-- Name: wslot tg_wslot_bu; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER tg_wslot_bu BEFORE UPDATE ON public.wslot FOR EACH ROW EXECUTE FUNCTION public.tg_wslot_bu();


--
-- Name: transition_table_base transition_table_base_ins_trig; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER transition_table_base_ins_trig AFTER INSERT ON public.transition_table_base REFERENCING NEW TABLE AS newtable FOR EACH STATEMENT EXECUTE FUNCTION public.transition_table_base_ins_func();


--
-- Name: transition_table_base transition_table_base_upd_trig; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER transition_table_base_upd_trig AFTER UPDATE ON public.transition_table_base REFERENCING OLD TABLE AS oldtable NEW TABLE AS newtable FOR EACH STATEMENT EXECUTE FUNCTION public.transition_table_base_upd_func();


--
-- Name: transition_table_level1 transition_table_level1_ri_parent_del_trigger; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER transition_table_level1_ri_parent_del_trigger AFTER DELETE ON public.transition_table_level1 REFERENCING OLD TABLE AS p FOR EACH STATEMENT EXECUTE FUNCTION public.transition_table_level1_ri_parent_del_func();


--
-- Name: transition_table_level1 transition_table_level1_ri_parent_upd_trigger; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER transition_table_level1_ri_parent_upd_trigger AFTER UPDATE ON public.transition_table_level1 REFERENCING OLD TABLE AS d NEW TABLE AS i FOR EACH STATEMENT EXECUTE FUNCTION public.transition_table_level1_ri_parent_upd_func();


--
-- Name: transition_table_level2 transition_table_level2_ri_child_ins_trigger; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER transition_table_level2_ri_child_ins_trigger AFTER INSERT ON public.transition_table_level2 REFERENCING NEW TABLE AS i FOR EACH STATEMENT EXECUTE FUNCTION public.transition_table_level2_ri_child_insupd_func();


--
-- Name: transition_table_level2 transition_table_level2_ri_child_upd_trigger; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER transition_table_level2_ri_child_upd_trigger AFTER UPDATE ON public.transition_table_level2 REFERENCING NEW TABLE AS i FOR EACH STATEMENT EXECUTE FUNCTION public.transition_table_level2_ri_child_insupd_func();


--
-- Name: test_tsvector tsvectorupdate; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER tsvectorupdate BEFORE INSERT OR UPDATE ON public.test_tsvector FOR EACH ROW EXECUTE FUNCTION tsvector_update_trigger('a', 'pg_catalog.english', 't');


--
-- Name: bar1 xtrig; Type: TRIGGER; Schema: public; Owner: ashutoshpg
--

CREATE TRIGGER xtrig AFTER UPDATE ON public.bar1 REFERENCING OLD TABLE AS old FOR EACH STATEMENT EXECUTE FUNCTION public.xtrig();


--
-- Name: fk fk_a_fkey; Type: FK CONSTRAINT; Schema: fkpart3; Owner: ashutoshpg
--

ALTER TABLE fkpart3.fk
    ADD CONSTRAINT fk_a_fkey FOREIGN KEY (a) REFERENCES fkpart3.pk(a);


--
-- Name: dropfk dropfk_a_fkey; Type: FK CONSTRAINT; Schema: fkpart4; Owner: ashutoshpg
--

ALTER TABLE ONLY fkpart4.dropfk
    ADD CONSTRAINT dropfk_a_fkey FOREIGN KEY (a) REFERENCES fkpart4.droppk(a);


--
-- Name: fk fk_a_fkey; Type: FK CONSTRAINT; Schema: fkpart5; Owner: ashutoshpg
--

ALTER TABLE fkpart5.fk
    ADD CONSTRAINT fk_a_fkey FOREIGN KEY (a) REFERENCES fkpart5.pk(a);


--
-- Name: gtest23q gtest23q_b_fkey; Type: FK CONSTRAINT; Schema: generated_stored_tests; Owner: ashutoshpg
--

ALTER TABLE ONLY generated_stored_tests.gtest23q
    ADD CONSTRAINT gtest23q_b_fkey FOREIGN KEY (b) REFERENCES generated_stored_tests.gtest23p(y);


--
-- Name: clstr_tst clstr_tst_con; Type: FK CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.clstr_tst
    ADD CONSTRAINT clstr_tst_con FOREIGN KEY (b) REFERENCES public.clstr_tst_s(rf_a);


--
-- Name: comment_test_child comment_test_child_fk; Type: FK CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.comment_test_child
    ADD CONSTRAINT comment_test_child_fk FOREIGN KEY (id) REFERENCES public.comment_test(id);


--
-- Name: CONSTRAINT comment_test_child_fk ON comment_test_child; Type: COMMENT; Schema: public; Owner: ashutoshpg
--

COMMENT ON CONSTRAINT comment_test_child_fk ON public.comment_test_child IS 'FOREIGN KEY constraint of comment_test_child';


--
-- Name: credit_card credit_card_cid_fkey; Type: FK CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.credit_card
    ADD CONSTRAINT credit_card_cid_fkey FOREIGN KEY (cid) REFERENCES public.customer(cid);


--
-- Name: credit_usage credit_usage_cid_fkey; Type: FK CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.credit_usage
    ADD CONSTRAINT credit_usage_cid_fkey FOREIGN KEY (cid) REFERENCES public.customer(cid);


--
-- Name: fk_partitioned_fk_4_2 fk_partitioned_fk_4_2_a_b_fkey; Type: FK CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.fk_partitioned_fk_4_2
    ADD CONSTRAINT fk_partitioned_fk_4_2_a_b_fkey FOREIGN KEY (a, b) REFERENCES public.fk_notpartitioned_pk(a, b) ON UPDATE SET NULL;


--
-- Name: fk_partitioned_fk_5_1 fk_partitioned_fk_5_1_a_b_fkey; Type: FK CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.fk_partitioned_fk_5_1
    ADD CONSTRAINT fk_partitioned_fk_5_1_a_b_fkey FOREIGN KEY (a, b) REFERENCES public.fk_notpartitioned_pk(a, b);


--
-- Name: fk_partitioned_fk_5 fk_partitioned_fk_5_a_b_fkey; Type: FK CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE public.fk_partitioned_fk_5
    ADD CONSTRAINT fk_partitioned_fk_5_a_b_fkey FOREIGN KEY (a, b) REFERENCES public.fk_notpartitioned_pk(a, b) ON UPDATE CASCADE ON DELETE CASCADE DEFERRABLE;


--
-- Name: fk_partitioned_fk_5 fk_partitioned_fk_5_a_b_fkey1; Type: FK CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE public.fk_partitioned_fk_5
    ADD CONSTRAINT fk_partitioned_fk_5_a_b_fkey1 FOREIGN KEY (a, b) REFERENCES public.fk_notpartitioned_pk(a, b) MATCH FULL ON UPDATE CASCADE ON DELETE CASCADE;


--
-- Name: fk_partitioned_fk fk_partitioned_fk_a_b_fkey; Type: FK CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE public.fk_partitioned_fk
    ADD CONSTRAINT fk_partitioned_fk_a_b_fkey FOREIGN KEY (a, b) REFERENCES public.fk_notpartitioned_pk(a, b) ON UPDATE CASCADE ON DELETE CASCADE;


--
-- Name: parted_self_fk parted_self_fk_id_abc_fkey; Type: FK CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE public.parted_self_fk
    ADD CONSTRAINT parted_self_fk_id_abc_fkey FOREIGN KEY (id_abc) REFERENCES public.parted_self_fk(id);


--
-- Name: rule_and_refint_t3 rule_and_refint_t3_id3a_id3b_fkey; Type: FK CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.rule_and_refint_t3
    ADD CONSTRAINT rule_and_refint_t3_id3a_id3b_fkey FOREIGN KEY (id3a, id3b) REFERENCES public.rule_and_refint_t1(id1a, id1b);


--
-- Name: rule_and_refint_t3 rule_and_refint_t3_id3a_id3c_fkey; Type: FK CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.rule_and_refint_t3
    ADD CONSTRAINT rule_and_refint_t3_id3a_id3c_fkey FOREIGN KEY (id3a, id3c) REFERENCES public.rule_and_refint_t2(id2a, id2c);


--
-- Name: temporal_fk2_mltrng2mltrng temporal_fk2_mltrng2mltrng_fk; Type: FK CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.temporal_fk2_mltrng2mltrng
    ADD CONSTRAINT temporal_fk2_mltrng2mltrng_fk FOREIGN KEY (parent_id1, parent_id2, PERIOD valid_at) REFERENCES public.temporal_mltrng2(id1, id2, PERIOD valid_at);


--
-- Name: temporal_fk2_rng2rng temporal_fk2_rng2rng_fk; Type: FK CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.temporal_fk2_rng2rng
    ADD CONSTRAINT temporal_fk2_rng2rng_fk FOREIGN KEY (parent_id1, parent_id2, PERIOD valid_at) REFERENCES public.temporal_rng2(id1, id2, PERIOD valid_at);


--
-- Name: temporal_fk_mltrng2mltrng temporal_fk_mltrng2mltrng_fk; Type: FK CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.temporal_fk_mltrng2mltrng
    ADD CONSTRAINT temporal_fk_mltrng2mltrng_fk FOREIGN KEY (parent_id, PERIOD valid_at) REFERENCES public.temporal_mltrng(id, PERIOD valid_at) ON DELETE RESTRICT;


--
-- Name: temporal_fk_rng2rng temporal_fk_rng2rng_fk; Type: FK CONSTRAINT; Schema: public; Owner: ashutoshpg
--

ALTER TABLE ONLY public.temporal_fk_rng2rng
    ADD CONSTRAINT temporal_fk_rng2rng_fk FOREIGN KEY (parent_id, PERIOD valid_at) REFERENCES public.temporal_rng(id, PERIOD valid_at) ON DELETE RESTRICT;


--
-- Name: ec1; Type: ROW SECURITY; Schema: public; Owner: ashutoshpg
--

ALTER TABLE public.ec1 ENABLE ROW LEVEL SECURITY;

--
-- Name: ec1 p1; Type: POLICY; Schema: public; Owner: ashutoshpg
--

CREATE POLICY p1 ON public.ec1 USING ((f1 OPERATOR(public.<) '5'::public.int8alias1));


--
-- Name: rls_tbl p1; Type: POLICY; Schema: regress_rls_schema; Owner: ashutoshpg
--

CREATE POLICY p1 ON regress_rls_schema.rls_tbl USING ((c1 > 5));


--
-- Name: rls_tbl_force p1; Type: POLICY; Schema: regress_rls_schema; Owner: ashutoshpg
--

CREATE POLICY p1 ON regress_rls_schema.rls_tbl_force USING ((c1 = 5)) WITH CHECK ((c1 < 5));


--
-- Name: rls_tbl p2; Type: POLICY; Schema: regress_rls_schema; Owner: ashutoshpg
--

CREATE POLICY p2 ON regress_rls_schema.rls_tbl FOR SELECT USING ((c1 <= 3));


--
-- Name: rls_tbl_force p2; Type: POLICY; Schema: regress_rls_schema; Owner: ashutoshpg
--

CREATE POLICY p2 ON regress_rls_schema.rls_tbl_force FOR SELECT USING ((c1 = 8));


--
-- Name: rls_tbl p3; Type: POLICY; Schema: regress_rls_schema; Owner: ashutoshpg
--

CREATE POLICY p3 ON regress_rls_schema.rls_tbl FOR UPDATE USING ((c1 <= 3)) WITH CHECK ((c1 > 5));


--
-- Name: rls_tbl_force p3; Type: POLICY; Schema: regress_rls_schema; Owner: ashutoshpg
--

CREATE POLICY p3 ON regress_rls_schema.rls_tbl_force FOR UPDATE USING ((c1 = 8)) WITH CHECK ((c1 >= 5));


--
-- Name: rls_tbl p4; Type: POLICY; Schema: regress_rls_schema; Owner: ashutoshpg
--

CREATE POLICY p4 ON regress_rls_schema.rls_tbl FOR DELETE USING ((c1 <= 3));


--
-- Name: rls_tbl_force p4; Type: POLICY; Schema: regress_rls_schema; Owner: ashutoshpg
--

CREATE POLICY p4 ON regress_rls_schema.rls_tbl_force FOR DELETE USING ((c1 = 8));


--
-- Name: rls_tbl; Type: ROW SECURITY; Schema: regress_rls_schema; Owner: ashutoshpg
--

ALTER TABLE regress_rls_schema.rls_tbl ENABLE ROW LEVEL SECURITY;

--
-- Name: rls_tbl_force; Type: ROW SECURITY; Schema: regress_rls_schema; Owner: ashutoshpg
--

ALTER TABLE regress_rls_schema.rls_tbl_force ENABLE ROW LEVEL SECURITY;

--
-- Name: SCHEMA generated_stored_tests; Type: ACL; Schema: -; Owner: ashutoshpg
--

GRANT USAGE ON SCHEMA generated_stored_tests TO PUBLIC;


--
-- Name: SCHEMA public; Type: ACL; Schema: -; Owner: pg_database_owner
--

REVOKE USAGE ON SCHEMA public FROM PUBLIC;
GRANT ALL ON SCHEMA public TO PUBLIC;


--
-- Name: COLUMN pg_authid.rolname; Type: ACL; Schema: pg_catalog; Owner: ashutoshpg
--

GRANT SELECT(rolname) ON TABLE pg_catalog.pg_authid TO ashutoshpg;


--
-- Name: COLUMN pg_authid.rolsuper; Type: ACL; Schema: pg_catalog; Owner: ashutoshpg
--

GRANT SELECT(rolsuper) ON TABLE pg_catalog.pg_authid TO ashutoshpg;


--
-- Name: COLUMN pg_proc.prosrc; Type: ACL; Schema: pg_catalog; Owner: ashutoshpg
--

GRANT SELECT(prosrc) ON TABLE pg_catalog.pg_proc TO ashutoshpg;


--
-- Name: TABLE datdba_only; Type: ACL; Schema: public; Owner: pg_database_owner
--

REVOKE ALL ON TABLE public.datdba_only FROM pg_database_owner;
GRANT SELECT,INSERT,REFERENCES,TRIGGER,TRUNCATE,MAINTAIN,UPDATE ON TABLE public.datdba_only TO pg_database_owner;


--
-- Name: TABLE my_credit_card_normal; Type: ACL; Schema: public; Owner: ashutoshpg
--

GRANT SELECT ON TABLE public.my_credit_card_normal TO PUBLIC;


--
-- Name: TABLE my_credit_card_secure; Type: ACL; Schema: public; Owner: ashutoshpg
--

GRANT SELECT ON TABLE public.my_credit_card_secure TO PUBLIC;


--
-- Name: TABLE my_credit_card_usage_normal; Type: ACL; Schema: public; Owner: ashutoshpg
--

GRANT SELECT ON TABLE public.my_credit_card_usage_normal TO PUBLIC;


--
-- Name: TABLE my_credit_card_usage_secure; Type: ACL; Schema: public; Owner: ashutoshpg
--

GRANT SELECT ON TABLE public.my_credit_card_usage_secure TO PUBLIC;


--
-- Name: TABLE my_property_normal; Type: ACL; Schema: public; Owner: ashutoshpg
--

GRANT SELECT ON TABLE public.my_property_normal TO PUBLIC;


--
-- Name: TABLE my_property_secure; Type: ACL; Schema: public; Owner: ashutoshpg
--

GRANT SELECT ON TABLE public.my_property_secure TO PUBLIC;


--
-- Name: test_event_trigger_guc; Type: EVENT TRIGGER; Schema: -; Owner: ashutoshpg
--

CREATE EVENT TRIGGER test_event_trigger_guc ON sql_drop
         WHEN TAG IN ('DROP POLICY')
   EXECUTE FUNCTION public.test_event_trigger_guc();


ALTER EVENT TRIGGER test_event_trigger_guc OWNER TO ashutoshpg;

--
--

