CREATE TABLE USR_GRCONTGEST(                              
   USR_CDGRUPCONTA          VARCHAR(03)         not null ,  
   USR_DSGRUPCONTA          VARCHAR(30)         not null ,  
   USR_IDINCICUSTO          VARCHAR(01)         not null ,  
   CONSTRAINT PK_USR_GRCONTGEST PRIMARY KEY (USR_CDGRUPCONTA))
GO

CREATE TABLE USR_EFETGEST(                
   USR_CDFILIAL             VARCHAR(04)           not null , 
   USR_DTEFETGEST           DATETIME              not null ,
   USR_CDSERVFILI           VARCHAR(05)           not null ,
   USR_QTEFETGEST           NUMERIC(10,3)         not null ,
   USR_VREFETGEST           NUMERIC(15,2)         not null ,
   USR_VRTTSERVGEST         NUMERIC(15,2)         not null ,
   CONSTRAINT PK_USR_EFETGEST_PK PRIMARY KEY (USR_CDFILIAL, USR_DTEFETGEST, USR_CDSERVFILI))
GO

CREATE TABLE USR_TXADMGEST(                
   USR_DTTXADMGEST         DATETIME             not null ,
   USR_CDFILIAL            VARCHAR(04)          not null ,
   USR_VRTXADMGEST         NUMERIC(15,2)        not null ,
   USR_IDPRINCIPAL         VARCHAR(01),
   CONSTRAINT PK_USR_TXADMGEST PRIMARY KEY (USR_DTTXADMGEST, USR_CDFILIAL))      
GO

CREATE TABLE USR_GRCONTLANGES(                              
   USR_CDFILIAL             VARCHAR(04)          not null ,  
   USR_DTGRCONTLANC         DATETIME             not null ,     
   USR_CDGRUPCONTA          VARCHAR(03)          not null ,  
   USR_VRGRCONTLANC         NUMERIC(15,2)        not null ,  
   CONSTRAINT PK_USR_GRCONTLANGES PRIMARY KEY (USR_CDFILIAL,USR_DTGRCONTLANC,USR_CDGRUPCONTA))
GO

