/**Begin D:\PDM\PDM_UPGRADE\pdm1\BCM_table.sql **/
IF NOT EXISTS (SELECT 1 FROM KSQL_USERTABLES WHERE KSQL_TABNAME = 'T_BCM_DSACCTMAINDATA') 
 CREATE TABLE T_BCM_DSACCTMAINDATA (
FID BIGINT DEFAULT 0 NOT NULL,
FACCOUNTCODELVL VARCHAR(64) DEFAULT ' ' NOT NULL,
FACCOUNTTYPECNNAME VARCHAR(64) DEFAULT ' ' NOT NULL,
FACCOUNTTYPECODE VARCHAR(64) DEFAULT ' ' NOT NULL,
FACCOUNTTYPEENNAME VARCHAR(64) DEFAULT ' ' NOT NULL,
FGROUPACCOUNTCODE VARCHAR(64) DEFAULT ' ' NOT NULL,
FGRPACCOUNTCODECNDESC VARCHAR(1000) DEFAULT ' ' NOT NULL,
FGRPACCOUNTCODECNNAME VARCHAR(256) DEFAULT ' ' NOT NULL,
FGRPACCOUNTCODEENDESC VARCHAR(1000) DEFAULT ' ' NOT NULL,
FGRPACCOUNTCODEENNAME VARCHAR(256) DEFAULT ' ' NOT NULL,
FHDHSEQ VARCHAR(20) DEFAULT ' ' NOT NULL,
FHDHTIMESTAMP DATETIME,
FRATEREVALUATIONFLAG VARCHAR(64) DEFAULT ' ' NOT NULL,
FSCOPEFLAG VARCHAR(64) DEFAULT ' ' NOT NULL,
FSTATUSTYPECNNAME VARCHAR(1000) DEFAULT ' ' NOT NULL,
FSTATUSTYPECODE VARCHAR(64) DEFAULT ' ' NOT NULL,
FSTATUSTYPEENNAME VARCHAR(1000) DEFAULT ' ' NOT NULL
);


IF NOT EXISTS (SELECT 1 FROM KSQL_USERTABLES WHERE KSQL_TABNAME = 'T_BCM_DSENTITYMAINDATA') 
 CREATE TABLE T_BCM_DSENTITYMAINDATA (
FID BIGINT DEFAULT 0 NOT NULL,
FCHINESEREGISTRATIONLOC VARCHAR(64) DEFAULT ' ' NOT NULL,
FCOMPANYCNNAME VARCHAR(256) DEFAULT ' ' NOT NULL,
FCOMPANYCODE VARCHAR(64) DEFAULT ' ' NOT NULL,
FCOMPANYENNAME VARCHAR(256) DEFAULT ' ' NOT NULL,
FENGLISHREGISTRATIONLOC VARCHAR(64) DEFAULT ' ' NOT NULL,
FHDHSEQ VARCHAR(20) DEFAULT ' ' NOT NULL,
FHDHTIMESTAMP DATETIME,
FLCCODE VARCHAR(64) DEFAULT ' ' NOT NULL
);


IF NOT EXISTS (SELECT 1 FROM KSQL_USERTABLES WHERE KSQL_TABNAME = 'T_BCM_DSCURRMAINDATA') 
 CREATE TABLE T_BCM_DSCURRMAINDATA (
FID BIGINT DEFAULT 0 NOT NULL,
FCURRENCYCODE VARCHAR(64) DEFAULT ' ' NOT NULL,
FCURRENCYDESC VARCHAR(256) DEFAULT ' ' NOT NULL,
FHDHSEQ VARCHAR(20) DEFAULT ' ' NOT NULL,
FHDHTIMESTAMP DATETIME
);



/**End D:\PDM\PDM_UPGRADE\pdm1\BCM_table.sql **/
