CREATE TABLE public.cmi_comissao_vendedor_faturado ( filial integer NOT NULL, orcamento integer NOT NULL, seq_ped integer NOT NULL, ficha integer NOT NULL, seq_ficha integer NOT NULL, fator numeric(18,6) NOT NULL, CONSTRAINT pk_cmi_comissao_vendedor_faturado PRIMARY KEY (filial, orcamento, seq_ped), CONSTRAINT fk_cmi_comissao_vendedor_faturado FOREIGN KEY (filial, orcamento) REFERENCES public.vnd_orcamento (filial_orc, orcamento) MATCH SIMPLE ON UPDATE NO ACTION ON DELETE NO ACTION ) TABLESPACE pg_default; ALTER TABLE public.cmi_comissao_vendedor_faturado OWNER to postgres;