CREATE COLUMN TABLE "SBODEMOPT"."ORTM" ("LineNum" INTEGER CS_INT NOT NULL , "Rtmdate" LONGDATE CS_LONGDATE, "AcctCode" NVARCHAR(15), "IsCard" NVARCHAR(1) DEFAULT 'N', "ActCurrncy" NVARCHAR(3), "ActRate" DECIMAL(21,6) CS_FIXED, "Balance" DECIMAL(21,6) CS_FIXED, "FrnBlnc" DECIMAL(21,6) CS_FIXED, "TransNum" INTEGER CS_INT DEFAULT 0, "Valid" NVARCHAR(1) DEFAULT 'N', "Delta" DECIMAL(21,6) CS_FIXED, "IsSysCurr" NVARCHAR(1) DEFAULT 'N' NOT NULL , "StornoDate" LONGDATE CS_LONGDATE, "RevalRate" DECIMAL(21,6) CS_FIXED, "UserSign" SMALLINT CS_INT, "BPLId" INTEGER CS_INT, "CntBlnc" DECIMAL(21,6) CS_FIXED, "TransAmtSC" DECIMAL(21,6) CS_FIXED, "BalDueSC" DECIMAL(21,6) CS_FIXED, "SCAdjust" NVARCHAR(1) DEFAULT 'N', PRIMARY KEY ("LineNum", "IsSysCurr")) UNLOAD PRIORITY 5  AUTO MERGE ;
CREATE INDEX "ORTM_SYS_CURR" ON "SBODEMOPT"."ORTM" ( "IsSysCurr" ASC )