/****** Object: Table [dbo].[TC_CostStatistic] Script Date: 2021/8/11 7:24:03 ******/ SET ANSI_NULLS ON GO SET QUOTED_IDENTIFIER ON GO CREATE TABLE [dbo].[TC_CostStatistic]( [CostStatisticCode] [nvarchar](50) NOT NULL, [ProjectId] [nvarchar](50) NULL, [Months] [datetime] NULL, [CompileMan] [nvarchar](50) NULL, [CompileDate] [datetime] NULL, CONSTRAINT [PK_TC_CostStatistic] PRIMARY KEY CLUSTERED ( [CostStatisticCode] ASC )WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY] ) ON [PRIMARY] GO ALTER TABLE [dbo].[TC_CostStatistic] WITH CHECK ADD CONSTRAINT [FK_TC_CostStatistic_Base_Project] FOREIGN KEY([ProjectId]) REFERENCES [dbo].[Base_Project] ([ProjectId]) GO ALTER TABLE [dbo].[TC_CostStatistic] CHECK CONSTRAINT [FK_TC_CostStatistic_Base_Project] GO ALTER TABLE [dbo].[TC_CostStatistic] WITH CHECK ADD CONSTRAINT [FK_TC_CostStatistic_Sys_User] FOREIGN KEY([CompileMan]) REFERENCES [dbo].[Sys_User] ([UserId]) GO ALTER TABLE [dbo].[TC_CostStatistic] CHECK CONSTRAINT [FK_TC_CostStatistic_Sys_User] GO EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'主键' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'TC_CostStatistic', @level2type=N'COLUMN',@level2name=N'CostStatisticCode' GO EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'项目号' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'TC_CostStatistic', @level2type=N'COLUMN',@level2name=N'ProjectId' GO EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'月份' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'TC_CostStatistic', @level2type=N'COLUMN',@level2name=N'Months' GO EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'编制人' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'TC_CostStatistic', @level2type=N'COLUMN',@level2name=N'CompileMan' GO EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'编制日期' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'TC_CostStatistic', @level2type=N'COLUMN',@level2name=N'CompileDate' GO EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'费用汇总表' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'TC_CostStatistic' GO