IF NOT EXISTS (SELECT 1 FROM sys.objects WHERE object_id = OBJECT_ID('[dbo].[mps_depart_base]') AND type = 'U')
CREATE TABLE [dbo].[mps_depart_base]
(
    [dp_id] int NOT NULL IDENTITY(1, 1),
    [dp_cmpid] int NULL DEFAULT((0)),
    [dp_code] varchar(20) COLLATE Chinese_PRC_CI_AS NULL DEFAULT(''),
    [dp_depart] nvarchar(50) COLLATE Chinese_PRC_CI_AS NULL DEFAULT(''),
    [dp_order] int NULL DEFAULT((999)),
    [dp_level] int NULL DEFAULT((0)),
    [dp_isgroup] int NULL DEFAULT((1)),
    [dp_fromcc] int NULL DEFAULT((1)),
    CONSTRAINT [PK_MPS_DEPART_BASE] PRIMARY KEY ([dp_id] ASC)
)