CREATE TABLE EQUALFORNE( 
	NREQUALFORNE   VARCHAR2(10)  NOT NULL,
    CDFILIAL       VARCHAR2(4)  NOT NULL, 
    CDREGIAO       VARCHAR2(3)  NOT NULL,
    CDFORNECED     VARCHAR2(21) NOT NULL,
    NRPEDIDOCOL    VARCHAR2(10) NOT NULL, 
    CDPRODUTO      VARCHAR2(10) NOT NULL,
    CDMARCA        VARCHAR2(5)  NOT NULL, 
    VRQUANTID      FLOAT, 
    VRULTCMP       FLOAT, 
    VRPRECMEDIO    FLOAT, 
    VRMELHORPRANT  FLOAT, 
    VRPRECANT      FLOAT, 
    VRTOTANT       FLOAT, 
    VRPRATUAL      FLOAT, 
    VRTOTATUAL     FLOAT, 
    VRPERCTUAL     FLOAT, 
    VRPRECECO      FLOAT, 
    VRTOTPRECECO   FLOAT,
    VRTOTPRECECOPI FLOAT, 
    VRPRECPIPEDCOL FLOAT, 
    VRPRECOBJ      FLOAT, 
    VRTOTPROBJ     FLOAT, 
    VRPRECNEG      FLOAT, 
    VRPERCNEG      FLOAT, 
    VRTOTNEG       FLOAT, 
    IDMELHORPREC   VARCHAR2(1) DEFAULT 'N', 
    VRTOTALFORNE   FLOAT,
	NRORG          NUMBER  	       DEFAULT         SYS_CONTEXT('nrorg_ctx','nrorg') NOT NULL,
	IDATIVO        VARCHAR2(1)     DEFAULT 'S' NOT NULL
		CONSTRAINT CKC_IDATIVO_EQUALFORNE CHECK (IDATIVO IN ('S','N')),
	DTINCLUSAO     DATE                  			NULL,
	DTULTATU       DATE                  			NULL,
	NRORGINCLUSAO  NUMBER          DEFAULT SYS_CONTEXT('nrorg_ctx','nrorg')		NULL,
	CDOPERINCLUSAO VARCHAR2(12)    DEFAULT '1' 		NULL,
	NRORGULTATU    NUMBER          DEFAULT SYS_CONTEXT('nrorg_ctx','nrorg')		NULL,
	CDOPERULTATU   VARCHAR2(12)    DEFAULT '1'
)
/