CREATE COLUMN TABLE "SBODEMOPT"."NFN1" ("ObjectCode" NVARCHAR(20) NOT NULL , "SeqCode" SMALLINT CS_INT DEFAULT 0 NOT NULL , "SeqName" NVARCHAR(8) NOT NULL , "InitialNum" INTEGER CS_INT DEFAULT 0, "NextNum" INTEGER CS_INT DEFAULT 0, "LastNum" INTEGER CS_INT, "SeriesStr" NVARCHAR(3), "SubStr" NVARCHAR(3), "Remark" NVARCHAR(50), "GroupCode" SMALLINT CS_INT DEFAULT 1, "Locked" NVARCHAR(1) DEFAULT 'N', "YearTransf" NVARCHAR(1) DEFAULT 'N', "Indicator" NVARCHAR(10) DEFAULT ' ', "Template" NVARCHAR(20), "NumSize" INTEGER CS_INT, "Prefix" NVARCHAR(8), "Suffix" NVARCHAR(8), "DocSubType" NVARCHAR(2) DEFAULT '--' NOT NULL , "Model" NVARCHAR(6) DEFAULT '0', "Location" INTEGER CS_INT, "BPLId" INTEGER CS_INT DEFAULT 0 NOT NULL , "IsDigital" NVARCHAR(1) DEFAULT 'N', "EnvTypeNFe" INTEGER CS_INT DEFAULT -1, PRIMARY KEY ("ObjectCode", "DocSubType", "SeqCode")) UNLOAD PRIORITY 5  AUTO MERGE ;
CREATE UNIQUE INDEX "NFN1_S_NAME" ON "SBODEMOPT"."NFN1" ( "ObjectCode" ASC, "DocSubType" ASC, "BPLId" ASC, "SeqName" ASC )