/**Begin D:\PDM_UPGRADE\PDM1\HRPTMC_table.sql **/
IF NOT EXISTS (SELECT 1 FROM KSQL_USERTABLES WHERE KSQL_TABNAME = 'T_HRPTMC_ANOBJSIDEBAR') 
 CREATE TABLE T_HRPTMC_ANOBJSIDEBAR (
FID BIGINT DEFAULT 0 NOT NULL,
FINDEX INT DEFAULT 0 NOT NULL,
FTYPE VARCHAR(50) DEFAULT ' ' NOT NULL,
FANOBJID BIGINT DEFAULT 0 NOT NULL,
FGROUPFIELD BIGINT 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_HRPTMC_ANGROUPFIELD') 
 CREATE TABLE T_HRPTMC_ANGROUPFIELD (
FID BIGINT DEFAULT 0 NOT NULL,
FINDEX INT DEFAULT 0 NOT NULL,
FNUMBER VARCHAR(60) DEFAULT ' ' NOT NULL,
FNAME NVARCHAR(100) DEFAULT ' ' NOT NULL,
FTYPE VARCHAR(50) DEFAULT ' ' NOT NULL,
FANOBJCALFIELD BIGINT DEFAULT 0 NOT NULL,
FANOBJFIELD BIGINT DEFAULT 0 NOT NULL,
FANOBJID BIGINT 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_HRPTMC_GROUPITEM') 
 CREATE TABLE T_HRPTMC_GROUPITEM (
FENTRYID BIGINT DEFAULT 0 NOT NULL,
FID BIGINT DEFAULT 0 NOT NULL,
FSEQ INT DEFAULT 0 NOT NULL,
FITEMNAME NVARCHAR(100) DEFAULT ' ' NOT NULL,
FITEMNUMBER VARCHAR(100) DEFAULT ' ' NOT NULL,
FITEMCONDITION NCLOB,
FISUNGROUPITEM CHAR(1) DEFAULT '0' NOT NULL
);


IF NOT EXISTS (SELECT 1 FROM KSQL_USERTABLES WHERE KSQL_TABNAME = 'T_HRPTMC_ANGROUPFIELD_L') 
 CREATE TABLE T_HRPTMC_ANGROUPFIELD_L (
FPKID VARCHAR(18) DEFAULT ' ' NOT NULL,
FID BIGINT DEFAULT 0 NOT NULL,
FLOCALEID VARCHAR(10) DEFAULT ' ' NOT NULL,
FNAME NVARCHAR(100) DEFAULT ' ' NOT NULL
);


IF NOT EXISTS (SELECT 1 FROM KSQL_USERTABLES WHERE KSQL_TABNAME = 'T_HRPTMC_GROUPITEM_L') 
 CREATE TABLE T_HRPTMC_GROUPITEM_L (
FPKID VARCHAR(18) DEFAULT ' ' NOT NULL,
FENTRYID BIGINT DEFAULT 0 NOT NULL,
FLOCALEID VARCHAR(10) DEFAULT ' ' NOT NULL,
FITEMNAME NVARCHAR(100) DEFAULT ' ' NOT NULL
);



/**End D:\PDM_UPGRADE\PDM1\HRPTMC_table.sql **/
