/**Begin E:\NextERP_PDM\PDM_UPGRADE\PDMS\branch_lastest\pdm\SYS_table.sql **/

IF NOT EXISTS (SELECT 1 FROM KSQL_USERTABLES WHERE KSQL_TABNAME = 'T_SVC_PRINTRESULT') 
 CREATE TABLE T_SVC_PRINTRESULT (
FID BIGINT DEFAULT 0 NOT NULL,
FTASKID BIGINT DEFAULT 0 NOT NULL,
FCREATORID BIGINT DEFAULT 0 NOT NULL,
FORGID BIGINT DEFAULT 0 NOT NULL,
FCREATETIME DATETIME DEFAULT GETDATE() NOT NULL,
FAPPID VARCHAR(36) DEFAULT ' ' NOT NULL,
FORMID VARCHAR(50) DEFAULT ' ' NOT NULL,
FDISKTYPE CHAR(1) DEFAULT '1' NOT NULL
);


IF NOT EXISTS (SELECT 1 FROM KSQL_USERTABLES WHERE KSQL_TABNAME = 'T_SVC_PRINTRESULT_DETAIL') 
 CREATE TABLE T_SVC_PRINTRESULT_DETAIL (
FENTRYID BIGINT DEFAULT 0 NOT NULL,
FID BIGINT DEFAULT 0 NOT NULL,
FSEQ INT DEFAULT 0 NOT NULL,
FILENAME NVARCHAR(150) DEFAULT ' ' NOT NULL,
FILEPATH VARCHAR(500) DEFAULT ' ' NOT NULL,
FILETYPE VARCHAR(20) DEFAULT ' ' NOT NULL,
FSOURCE CHAR(1) DEFAULT 'B' NOT NULL
);



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