/**Begin D:\DBA\1.4\PDM_UPGRADE\PDM1\BCM_table.sql **/
IF NOT EXISTS (SELECT 1 FROM KSQL_USERTABLES WHERE KSQL_TABNAME = 'T_BCM_LOCKSCOPE') 
 CREATE TABLE T_BCM_LOCKSCOPE (
FID BIGINT DEFAULT 0 NOT NULL,
FMODELID BIGINT DEFAULT 0 NOT NULL,
FSCENE VARCHAR(50) DEFAULT ' ' NOT NULL,
FYEAR VARCHAR(50) DEFAULT ' ' NOT NULL,
FPERIOD VARCHAR(50) DEFAULT ' ' NOT NULL,
FCURRENCY VARCHAR(50) DEFAULT ' ' NOT NULL,
FCOMBINEKEY VARCHAR(100) DEFAULT ' ' NOT NULL,
FSTAGEID BIGINT DEFAULT 0 NOT NULL,
FSCHEMEID BIGINT DEFAULT 0 NOT NULL,
FSCOPENAME VARCHAR(255) DEFAULT ' ' NOT NULL,
FLOCKDIM NCLOB,
FTYPE CHAR(1) DEFAULT '0' NOT NULL,
FCREATORID BIGINT DEFAULT 0 NOT NULL,
FCREATETIME DATETIME,
FMODIFIERID BIGINT DEFAULT 0 NOT NULL,
FMODIFYTIME DATETIME
);


IF NOT EXISTS (SELECT 1 FROM KSQL_USERTABLES WHERE KSQL_TABNAME = 'T_BCM_LOCKSCOPEORG') 
 CREATE TABLE T_BCM_LOCKSCOPEORG (
FID BIGINT DEFAULT 0 NOT NULL,
FMODELID BIGINT DEFAULT 0 NOT NULL,
FLOCKSCOPEID BIGINT DEFAULT 0 NOT NULL,
FORG VARCHAR(50) DEFAULT ' ' NOT NULL
);



/**End D:\DBA\1.4\PDM_UPGRADE\PDM1\BCM_table.sql **/
