/**Begin E:\NextERP_PDM\PDM_UPGRADE\PDMS\branch_lastest\pdm\IM_table.sql **/
IF NOT EXISTS (SELECT 1 FROM KSQL_USERTABLES WHERE KSQL_TABNAME = 'T_IM_WB_INTERFACECFG') 
 CREATE TABLE T_IM_WB_INTERFACECFG (
FID BIGINT DEFAULT 0 NOT NULL,
FNUMBER NVARCHAR(30) DEFAULT ' ' NOT NULL,
FNAME NVARCHAR(50) DEFAULT ' ' NOT NULL,
FMASTERID BIGINT DEFAULT 0 NOT NULL,
FSTATUS CHAR(1) DEFAULT 'C' NOT NULL,
FENABLE CHAR(1) DEFAULT '1' NOT NULL,
FCREATORID BIGINT DEFAULT 0 NOT NULL,
FMODIFIERID BIGINT DEFAULT 0 NOT NULL,
FCREATETIME DATETIME,
FMODIFYTIME DATETIME,
FSRCBILL NVARCHAR(50) DEFAULT ' ' NOT NULL,
FTARBILL NVARCHAR(50) DEFAULT ' ' NOT NULL,
FBOTP NVARCHAR(50) DEFAULT ' ' NOT NULL,
FTASKTYPE BIGINT DEFAULT 0 NOT NULL,
FLOADTASKDIRECT CHAR(1) DEFAULT '0' NOT NULL,
FISPRESET CHAR(1) DEFAULT '0' NOT NULL,
FDESCRIPTION NVARCHAR(2000) DEFAULT ' ' NOT NULL
);


IF NOT EXISTS (SELECT 1 FROM KSQL_USERTABLES WHERE KSQL_TABNAME = 'T_IM_WB_INTERFACECFG_L') 
 CREATE TABLE T_IM_WB_INTERFACECFG_L (
FID BIGINT DEFAULT 0 NOT NULL,
FPKID VARCHAR(36) DEFAULT ' ' NOT NULL,
FLOCALEID VARCHAR(10) DEFAULT ' ' NOT NULL,
FNAME NVARCHAR(50) DEFAULT ' ' NOT NULL,
FDESCRIPTION NVARCHAR(2000) DEFAULT ' ' NOT NULL
);

IF NOT EXISTS (SELECT 1 FROM KSQL_USERTABLES WHERE KSQL_TABNAME = 'T_IM_WB_INTERFACECFG_E') 
 CREATE TABLE T_IM_WB_INTERFACECFG_E (
FENTRYID BIGINT DEFAULT 0 NOT NULL,
FID BIGINT DEFAULT 0 NOT NULL,
FSEQ BIGINT DEFAULT 0 NOT NULL,
FISSHOW CHAR(1) DEFAULT '1' NOT NULL,
FISLOCK CHAR(1) DEFAULT '1' NOT NULL,
FISMUSTINPUT CHAR(1) DEFAULT '0' NOT NULL,
FWBTAB NVARCHAR(50) DEFAULT ' ' NOT NULL,
FINTERFACEFIELD NVARCHAR(50) DEFAULT ' ' NOT NULL,
FTARBILLFIELD NVARCHAR(50) DEFAULT ' ' NOT NULL
);


/**End E:\NextERP_PDM\PDM_UPGRADE\PDMS\branch_lastest\pdm\IM_table.sql **/