IF NOT EXISTS (SELECT 1 FROM sys.objects WHERE object_id = OBJECT_ID('[dbo].[sys_sql_ds]') AND type = 'U')
CREATE TABLE [dbo].[sys_sql_ds]
(
    [dsid] int NOT NULL IDENTITY(1, 1),
    [parseid] int NULL,
    [dsname] varchar(20) COLLATE Chinese_PRC_CI_AS NULL,
    [predsname] varchar(20) COLLATE Chinese_PRC_CI_AS NULL,
    [pretbname] varchar(20) COLLATE Chinese_PRC_CI_AS NULL,
    [shortname] varchar(20) COLLATE Chinese_PRC_CI_AS NULL,
    [fullname] varchar(100) COLLATE Chinese_PRC_CI_AS NULL,
    [dschain] varchar(100) COLLATE Chinese_PRC_CI_AS NULL,
    [keyval] varchar(100) COLLATE Chinese_PRC_CI_AS NULL,
    [tbname] varchar(20) COLLATE Chinese_PRC_CI_AS NULL,
    [keyfld] varchar(20) COLLATE Chinese_PRC_CI_AS NULL,
    [prelnkfld] varchar(20) COLLATE Chinese_PRC_CI_AS NULL,
    [biztype] varchar(20) COLLATE Chinese_PRC_CI_AS NULL,
    [bizid] int NULL,
    [ord2tag] int NULL,
    [row] int NULL,
    [col] int NULL,
    [sqlCond] varchar(1000) COLLATE Chinese_PRC_CI_AS NULL,
    [sqlGrp] varchar(1000) COLLATE Chinese_PRC_CI_AS NULL,
    [configName] varchar(50) COLLATE Chinese_PRC_CI_AS NULL,
    [idParamVar] varchar(50) COLLATE Chinese_PRC_CI_AS NULL,
    [isDetailTable] int NULL,
    [isUpper] int NULL,
    [isroot] int NULL,
    [forupdate] int NULL,
    [forInsert] int NULL,
    [fordelete] int NULL,
    [getOrder] int NULL,
    CONSTRAINT [PK_SYS_SQL_DS] PRIMARY KEY ([dsid] ASC)
)