Sunday, 19 September 2021

Create Sequence in tables

CREATE SEQUENCE public.seq_abcded_id
    INCREMENT 1
    START 1
    MINVALUE 1
    MAXVALUE 9223372036854775807
    CACHE 1;

ALTER SEQUENCE public.seq_abcded_id
    OWNER TO postgres;
CREATE TABLE public.abcde
(
    id integer NOT NULL DEFAULT nextval('seq_abcded_id'::regclass),
    name character varying(100),
    PRIMARY KEY (id)
)
WITH (
    OIDS = FALSE
);

ALTER TABLE public.abcde
    OWNER to postgres;

DBT - Models

Models are where your developers spend most of their time within a dbt environment. Models are primarily written as a select statement and ...