CREATE COLUMN TABLE "SBODEMODE"."TXD4" ("DocEntry" INTEGER CS_INT NOT NULL , "ObjType" INTEGER CS_INT NOT NULL , "LogInstanc" INTEGER CS_INT DEFAULT 0, "LineNum" INTEGER CS_INT NOT NULL , "DpmObjType" INTEGER CS_INT, "DpmDocEntr" INTEGER CS_INT, "DpmDocNum" INTEGER CS_INT, "PmnObjType" INTEGER CS_INT, "PmnDocEntr" INTEGER CS_INT, "PmnDocNum" INTEGER CS_INT, "PmnTaxDate" LONGDATE CS_LONGDATE, "TrsfrDate" LONGDATE CS_LONGDATE, "TrsfrRef" NVARCHAR(27), "DrawnSum" DECIMAL(21,6) CS_FIXED, "DrawnSumFc" DECIMAL(21,6) CS_FIXED, "DrawnSumSc" DECIMAL(21,6) CS_FIXED, "DocCur" NVARCHAR(3), "Vat" DECIMAL(21,6) CS_FIXED, "VatFc" DECIMAL(21,6) CS_FIXED, "VatSc" DECIMAL(21,6) CS_FIXED, "Gross" DECIMAL(21,6) CS_FIXED, "GrossFc" DECIMAL(21,6) CS_FIXED, "GrossSc" DECIMAL(21,6) CS_FIXED, PRIMARY KEY ("DocEntry", "LineNum", "ObjType")) UNLOAD PRIORITY 5  AUTO MERGE ;
CREATE INDEX "TXD4_DOC_ENTRY" ON "SBODEMODE"."TXD4" ( "DocEntry" ASC )