/*
=======================================================================================
'Criaçaõ de tabela
'DT Revisão: 27/12/2023
'Revisado por: Willian José
'=======================================================================================
*/
IF NOT EXISTS (SELECT * FROM sysobjects WHERE name='GT_CONFIG_CFOP' and xtype='U')
BEGIN
	-- Criação da tabela GT_CONFIG_CFOP
	CREATE TABLE GT_CONFIG_CFOP
	(
		CD_EMP              INT,
		CD_FILIAL           INT,
		CD_GT_CONFIG_CFOP   INT IDENTITY (1,1) PRIMARY KEY,
		CD_CONFIG_GEST_TRIB INT,
		CFOP                VARCHAR(10),
		DS_CFOP             VARCHAR(100),
		TP_CFOP             VARCHAR(20),
		CD_USU              INT,
		DT_ULT_ALT          DATETIME,

		-- Definindo as chaves primárias
		--PRIMARY KEY (CD_EMP, CD_FILIAL, CD_GT_CONFIG_CFOP)
	);
END