日期:2014-05-18 浏览次数:20537 次
if exists (select * from sysobjects where id = OBJECT_ID('[ManualSign]') and OBJECTPROPERTY(id, 'IsUserTable') = 1) DROP TABLE [ManualSign] CREATE TABLE [ManualSign] ( [ID] [int] IDENTITY (1, 1) NOT NULL, [UserId] [varchar] (50) NOT NULL, [Dao] [bit] NULL DEFAULT (0), [ChiDao] [decimal] (18,2) NULL, [ZaoTui] [decimal] (18,2) NULL, [KuangGong] [decimal] (18,2) NULL, [QingJia] [decimal] (18,2) NULL DEFAULT (0), [FangJia] [decimal] (18,2) NULL DEFAULT (0), [LrUserId] [varchar] (50) NOT NULL, [LrDate] [smalldatetime] NOT NULL DEFAULT (getdate()), [AddDate] [smalldatetime] NOT NULL DEFAULT (getdate()), [Remarks] [varchar] (200) NULL) ALTER TABLE [ManualSign] WITH NOCHECK ADD CONSTRAINT [PK_ManualSign] PRIMARY KEY NONCLUSTERED ( [ID] ) SET IDENTITY_INSERT [ManualSign] ON INSERT [ManualSign] ([ID],[UserId],[Dao],[ChiDao],[ZaoTui],[KuangGong],[QingJia],[FangJia],[LrUserId],[LrDate],[AddDate]) VALUES ( 3,N'admin',1,0.00,0.00,0.00,0.00,0.00,N'admin',N'2011-12-21 0:00:00',N'2011-12-21 14:55:00') INSERT [ManualSign] ([ID],[UserId],[Dao],[ChiDao],[ZaoTui],[KuangGong],[QingJia],[FangJia],[LrUserId],[LrDate],[AddDate]) VALUES ( 4,N'admin',1,0.00,0.00,0.00,0.00,0.00,N'admin',N'2011-12-23 0:00:00',N'2011-12-23 0:36:00') SET IDENTITY_INSERT [ManualSign] OFF
CREATE TABLE [ManualSign] ( [ID] [int] IDENTITY (1, 1) NOT NULL, [UserId] [varchar] (50) NOT NULL, [Type] [varchar] (10) NOT NULL, [Attendance] [varchar] (20) NOT NULL, [LrUserId] [varchar] (50) NOT NULL, [LrDate] [smalldatetime] NOT NULL DEFAULT (getdate()), [AddDate] [smalldatetime] NOT NULL DEFAULT (getdate()), [Remarks] [varchar] (200) NULL) INSERT [ManualSign] ([ID],[UserId],[Type],[Attendance],[LrUserId],[LrDate],[AddDate]) VALUES ( 3,N'admin','ChiDao',0.5,N'admin',N'2011-12-21 0:00:00',N'2011-12-21 14:55:00') INSERT [ManualSign] ([ID],[UserId],[Type],[Attendance],[LrUserId],[LrDate],[AddDate]) VALUES ( 3,N'admin','KuangGong',2.0,N'admin',N'2011-12-21 0:00:00',N'2011-12-21 14:55:00')
------解决方案--------------------