123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112 |
-
-
-
-
- CREATE TABLE pk_bigserial (
- id bigint NOT NULL,
- some_text character varying,
- some_int integer,
- created_at timestamp with time zone DEFAULT now() NOT NULL,
- updated_at timestamp with time zone
- );
-
-
-
-
-
- CREATE SEQUENCE pk_bigserial_id_seq
- START WITH 1
- INCREMENT BY 1
- NO MINVALUE
- NO MAXVALUE
- CACHE 1;
-
-
-
-
-
-
- ALTER SEQUENCE pk_bigserial_id_seq OWNED BY pk_bigserial.id;
-
-
-
-
-
-
- CREATE TABLE pk_guid (
- id uuid DEFAULT get_uuid() NOT NULL,
- some_text character varying,
- some_int integer,
- created_at timestamp with time zone DEFAULT now() NOT NULL,
- updated_at timestamp with time zone
- );
-
-
-
-
-
- ALTER TABLE ONLY pk_bigserial ALTER COLUMN id SET DEFAULT nextval('pk_bigserial_id_seq'::regclass);
-
-
-
-
-
- ALTER TABLE ONLY pk_bigserial
- ADD CONSTRAINT pk_bigserial_pkey PRIMARY KEY (id);
-
-
-
-
-
-
- ALTER TABLE ONLY pk_bigserial
- ADD CONSTRAINT pk_bigserial_some_text_key UNIQUE (some_text);
-
-
-
-
-
-
- ALTER TABLE ONLY pk_guid
- ADD CONSTRAINT pk_guid_pkey PRIMARY KEY (id);
-
-
-
-
-
-
- ALTER TABLE ONLY pk_guid
- ADD CONSTRAINT pk_guid_some_text_key UNIQUE (some_text);
-
-
-
-
-
-
- CREATE TRIGGER pk_bigserial_lu_on_row_delete BEFORE DELETE ON pk_bigserial FOR EACH ROW EXECUTE PROCEDURE lu_on_row_delete();
-
-
-
-
-
-
- CREATE TRIGGER pk_bigserial_lu_on_row_update BEFORE UPDATE ON pk_bigserial FOR EACH ROW EXECUTE PROCEDURE lu_on_row_update();
-
-
-
-
-
-
- CREATE TRIGGER pk_guid_lu_on_row_delete BEFORE DELETE ON pk_guid FOR EACH ROW EXECUTE PROCEDURE lu_on_row_delete();
-
-
-
-
-
-
- CREATE TRIGGER pk_guid_lu_on_row_update BEFORE UPDATE ON pk_guid FOR EACH ROW EXECUTE PROCEDURE lu_on_row_update();
-
-
-
-
|