预约系统(一) 数据库设计

数据库sql server 2008

名称:DB_Date_Plan

表:T_bm,T_hys_plan,T_kryy_plan,T_meetingroom,T_room,T_time,T_userInfo

  1 USE [DB_Date_Plan]
  2 GO
  3 /****** Object:  Table [dbo].[T_userInfo]    Script Date: 07/13/2017 08:38:16 ******/
  4 SET ANSI_NULLS ON
  5 GO
  6 SET QUOTED_IDENTIFIER ON
  7 GO
  8 CREATE TABLE [dbo].[T_userInfo](
  9     [id] [int] IDENTITY(1,1) NOT NULL,
 10     [userName] [nvarchar](50) NULL,
 11     [userPassword] [nvarchar](50) NULL,
 12     [userEmail] [nvarchar](50) NULL,
 13     [user_BM] [nvarchar](50) NULL,
 14     [add_time] [datetime] NULL,
 15     [user_FullName] [nvarchar](50) NULL,
 16     [user_Power] [nvarchar](50) NULL,
 17  CONSTRAINT [PK_T_userInfo] PRIMARY KEY CLUSTERED
 18 (
 19     [id] ASC
 20 )WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
 21 ) ON [PRIMARY]
 22 GO
 23 EXEC sys.sp_addextendedproperty @name=N‘MS_Description‘, @value=N‘用户权限,1-用户权限,2-管理员权限,3-超级权限‘ , @level0type=N‘SCHEMA‘,@level0name=N‘dbo‘, @level1type=N‘TABLE‘,@level1name=N‘T_userInfo‘, @level2type=N‘COLUMN‘,@level2name=N‘user_Power‘
 24 GO
 25 /****** Object:  Table [dbo].[T_room]    Script Date: 07/13/2017 08:38:16 ******/
 26 SET ANSI_NULLS ON
 27 GO
 28 SET QUOTED_IDENTIFIER ON
 29 GO
 30 CREATE TABLE [dbo].[T_room](
 31     [id] [bigint] IDENTITY(1,1) NOT NULL,
 32     [room_id] [nvarchar](50) NULL,
 33     [room_mc] [nvarchar](50) NULL,
 34     [adder] [nvarchar](50) NULL,
 35     [add_time] [datetime] NULL,
 36  CONSTRAINT [PK_T_room] PRIMARY KEY CLUSTERED
 37 (
 38     [id] ASC
 39 )WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
 40 ) ON [PRIMARY]
 41 GO
 42 EXEC sys.sp_addextendedproperty @name=N‘MS_Description‘, @value=N‘会议室编号‘ , @level0type=N‘SCHEMA‘,@level0name=N‘dbo‘, @level1type=N‘TABLE‘,@level1name=N‘T_room‘, @level2type=N‘COLUMN‘,@level2name=N‘room_id‘
 43 GO
 44 EXEC sys.sp_addextendedproperty @name=N‘MS_Description‘, @value=N‘会议室名称‘ , @level0type=N‘SCHEMA‘,@level0name=N‘dbo‘, @level1type=N‘TABLE‘,@level1name=N‘T_room‘, @level2type=N‘COLUMN‘,@level2name=N‘room_mc‘
 45 GO
 46 /****** Object:  Table [dbo].[T_kryy_plan]    Script Date: 07/13/2017 08:38:16 ******/
 47 SET ANSI_NULLS ON
 48 GO
 49 SET QUOTED_IDENTIFIER ON
 50 GO
 51 CREATE TABLE [dbo].[T_kryy_plan](
 52     [id] [bigint] IDENTITY(1,1) NOT NULL,
 53     [adder] [nvarchar](50) NULL,
 54     [add_time] [datetime] NULL,
 55     [rq] [nvarchar](50) NULL,
 56     [sjd] [nvarchar](50) NULL,
 57     [yyr] [nvarchar](50) NULL,
 58     [yybm] [nvarchar](50) NULL,
 59     [in_time] [datetime] NULL,
 60     [out_time] [datetime] NULL,
 61     [krxm] [nvarchar](50) NULL,
 62     [krgs] [nvarchar](50) NULL,
 63     [mqzt] [nvarchar](50) NULL,
 64     [ztsj] [nvarchar](50) NULL,
 65     [bz] [nvarchar](50) NULL,
 66     [flax] [nvarchar](50) NULL,
 67     [time_begin] [nvarchar](50) NULL,
 68     [time_end] [nvarchar](50) NULL,
 69  CONSTRAINT [PK_T_kryy_plan] PRIMARY KEY CLUSTERED
 70 (
 71     [id] ASC
 72 )WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
 73 ) ON [PRIMARY]
 74 GO
 75 EXEC sys.sp_addextendedproperty @name=N‘MS_Description‘, @value=N‘预约日期‘ , @level0type=N‘SCHEMA‘,@level0name=N‘dbo‘, @level1type=N‘TABLE‘,@level1name=N‘T_kryy_plan‘, @level2type=N‘COLUMN‘,@level2name=N‘rq‘
 76 GO
 77 EXEC sys.sp_addextendedproperty @name=N‘MS_Description‘, @value=N‘时间段‘ , @level0type=N‘SCHEMA‘,@level0name=N‘dbo‘, @level1type=N‘TABLE‘,@level1name=N‘T_kryy_plan‘, @level2type=N‘COLUMN‘,@level2name=N‘sjd‘
 78 GO
 79 EXEC sys.sp_addextendedproperty @name=N‘MS_Description‘, @value=N‘预约人‘ , @level0type=N‘SCHEMA‘,@level0name=N‘dbo‘, @level1type=N‘TABLE‘,@level1name=N‘T_kryy_plan‘, @level2type=N‘COLUMN‘,@level2name=N‘yyr‘
 80 GO
 81 EXEC sys.sp_addextendedproperty @name=N‘MS_Description‘, @value=N‘预约人部门‘ , @level0type=N‘SCHEMA‘,@level0name=N‘dbo‘, @level1type=N‘TABLE‘,@level1name=N‘T_kryy_plan‘, @level2type=N‘COLUMN‘,@level2name=N‘yybm‘
 82 GO
 83 EXEC sys.sp_addextendedproperty @name=N‘MS_Description‘, @value=N‘入厂时间‘ , @level0type=N‘SCHEMA‘,@level0name=N‘dbo‘, @level1type=N‘TABLE‘,@level1name=N‘T_kryy_plan‘, @level2type=N‘COLUMN‘,@level2name=N‘in_time‘
 84 GO
 85 EXEC sys.sp_addextendedproperty @name=N‘MS_Description‘, @value=N‘离厂时间‘ , @level0type=N‘SCHEMA‘,@level0name=N‘dbo‘, @level1type=N‘TABLE‘,@level1name=N‘T_kryy_plan‘, @level2type=N‘COLUMN‘,@level2name=N‘out_time‘
 86 GO
 87 EXEC sys.sp_addextendedproperty @name=N‘MS_Description‘, @value=N‘客人姓名‘ , @level0type=N‘SCHEMA‘,@level0name=N‘dbo‘, @level1type=N‘TABLE‘,@level1name=N‘T_kryy_plan‘, @level2type=N‘COLUMN‘,@level2name=N‘krxm‘
 88 GO
 89 EXEC sys.sp_addextendedproperty @name=N‘MS_Description‘, @value=N‘客人单位‘ , @level0type=N‘SCHEMA‘,@level0name=N‘dbo‘, @level1type=N‘TABLE‘,@level1name=N‘T_kryy_plan‘, @level2type=N‘COLUMN‘,@level2name=N‘krgs‘
 90 GO
 91 EXEC sys.sp_addextendedproperty @name=N‘MS_Description‘, @value=N‘目前状态‘ , @level0type=N‘SCHEMA‘,@level0name=N‘dbo‘, @level1type=N‘TABLE‘,@level1name=N‘T_kryy_plan‘, @level2type=N‘COLUMN‘,@level2name=N‘mqzt‘
 92 GO
 93 EXEC sys.sp_addextendedproperty @name=N‘MS_Description‘, @value=N‘状态更新时间‘ , @level0type=N‘SCHEMA‘,@level0name=N‘dbo‘, @level1type=N‘TABLE‘,@level1name=N‘T_kryy_plan‘, @level2type=N‘COLUMN‘,@level2name=N‘ztsj‘
 94 GO
 95 EXEC sys.sp_addextendedproperty @name=N‘MS_Description‘, @value=N‘备注‘ , @level0type=N‘SCHEMA‘,@level0name=N‘dbo‘, @level1type=N‘TABLE‘,@level1name=N‘T_kryy_plan‘, @level2type=N‘COLUMN‘,@level2name=N‘bz‘
 96 GO
 97 EXEC sys.sp_addextendedproperty @name=N‘MS_Description‘, @value=N‘标记‘ , @level0type=N‘SCHEMA‘,@level0name=N‘dbo‘, @level1type=N‘TABLE‘,@level1name=N‘T_kryy_plan‘, @level2type=N‘COLUMN‘,@level2name=N‘flax‘
 98 GO
 99 /****** Object:  Table [dbo].[T_bm]    Script Date: 07/13/2017 08:38:16 ******/
100 SET ANSI_NULLS ON
101 GO
102 SET QUOTED_IDENTIFIER ON
103 GO
104 CREATE TABLE [dbo].[T_bm](
105     [id] [bigint] IDENTITY(1,1) NOT NULL,
106     [bm_no] [nvarchar](50) NULL,
107     [bm_mc] [nvarchar](50) NULL,
108     [adder] [nvarchar](50) NULL,
109     [add_time] [datetime] NULL,
110  CONSTRAINT [PK_T_bm] PRIMARY KEY CLUSTERED
111 (
112     [id] ASC
113 )WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
114 ) ON [PRIMARY]
115 GO
116 EXEC sys.sp_addextendedproperty @name=N‘MS_Description‘, @value=N‘部门代号‘ , @level0type=N‘SCHEMA‘,@level0name=N‘dbo‘, @level1type=N‘TABLE‘,@level1name=N‘T_bm‘, @level2type=N‘COLUMN‘,@level2name=N‘bm_no‘
117 GO
118 EXEC sys.sp_addextendedproperty @name=N‘MS_Description‘, @value=N‘部门名称‘ , @level0type=N‘SCHEMA‘,@level0name=N‘dbo‘, @level1type=N‘TABLE‘,@level1name=N‘T_bm‘, @level2type=N‘COLUMN‘,@level2name=N‘bm_mc‘
119 GO
120 EXEC sys.sp_addextendedproperty @name=N‘MS_Description‘, @value=N‘创建人‘ , @level0type=N‘SCHEMA‘,@level0name=N‘dbo‘, @level1type=N‘TABLE‘,@level1name=N‘T_bm‘, @level2type=N‘COLUMN‘,@level2name=N‘adder‘
121 GO
122 EXEC sys.sp_addextendedproperty @name=N‘MS_Description‘, @value=N‘创建时间‘ , @level0type=N‘SCHEMA‘,@level0name=N‘dbo‘, @level1type=N‘TABLE‘,@level1name=N‘T_bm‘, @level2type=N‘COLUMN‘,@level2name=N‘add_time‘
123 GO
124 /****** Object:  Table [dbo].[T_hys_plan]    Script Date: 07/13/2017 08:38:16 ******/
125 SET ANSI_NULLS ON
126 GO
127 SET QUOTED_IDENTIFIER ON
128 GO
129 CREATE TABLE [dbo].[T_hys_plan](
130     [id] [bigint] IDENTITY(1,1) NOT NULL,
131     [add_time] [datetime] NULL,
132     [adder] [nvarchar](50) NULL,
133     [rq] [nvarchar](50) NULL,
134     [time_begin] [nvarchar](50) NULL,
135     [time_end] [nvarchar](50) NULL,
136     [hys] [nvarchar](50) NULL,
137     [yyr] [nvarchar](50) NULL,
138     [yybm] [nvarchar](50) NULL,
139     [hyzt] [nvarchar](100) NULL,
140     [mqzt] [nvarchar](50) NULL,
141     [lock_key] [nvarchar](50) NULL,
142     [flax_while] [nvarchar](50) NULL,
143     [flax_bz] [nvarchar](200) NULL,
144     [zhou_x] [nvarchar](50) NULL,
145     [yue_x] [nvarchar](50) NULL,
146     [day_x] [nvarchar](50) NULL,
147     [bz] [nvarchar](50) NULL,
148     [flax] [nvarchar](50) NULL,
149  CONSTRAINT [PK_T_hys] PRIMARY KEY CLUSTERED
150 (
151     [id] ASC
152 )WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
153 ) ON [PRIMARY]
154 GO
155 EXEC sys.sp_addextendedproperty @name=N‘MS_Description‘, @value=N‘创建时间‘ , @level0type=N‘SCHEMA‘,@level0name=N‘dbo‘, @level1type=N‘TABLE‘,@level1name=N‘T_hys_plan‘, @level2type=N‘COLUMN‘,@level2name=N‘add_time‘
156 GO
157 EXEC sys.sp_addextendedproperty @name=N‘MS_Description‘, @value=N‘创建人‘ , @level0type=N‘SCHEMA‘,@level0name=N‘dbo‘, @level1type=N‘TABLE‘,@level1name=N‘T_hys_plan‘, @level2type=N‘COLUMN‘,@level2name=N‘adder‘
158 GO
159 EXEC sys.sp_addextendedproperty @name=N‘MS_Description‘, @value=N‘预约日期‘ , @level0type=N‘SCHEMA‘,@level0name=N‘dbo‘, @level1type=N‘TABLE‘,@level1name=N‘T_hys_plan‘, @level2type=N‘COLUMN‘,@level2name=N‘rq‘
160 GO
161 EXEC sys.sp_addextendedproperty @name=N‘MS_Description‘, @value=N‘预约开始时间‘ , @level0type=N‘SCHEMA‘,@level0name=N‘dbo‘, @level1type=N‘TABLE‘,@level1name=N‘T_hys_plan‘, @level2type=N‘COLUMN‘,@level2name=N‘time_begin‘
162 GO
163 EXEC sys.sp_addextendedproperty @name=N‘MS_Description‘, @value=N‘预约结束时间‘ , @level0type=N‘SCHEMA‘,@level0name=N‘dbo‘, @level1type=N‘TABLE‘,@level1name=N‘T_hys_plan‘, @level2type=N‘COLUMN‘,@level2name=N‘time_end‘
164 GO
165 EXEC sys.sp_addextendedproperty @name=N‘MS_Description‘, @value=N‘会议室‘ , @level0type=N‘SCHEMA‘,@level0name=N‘dbo‘, @level1type=N‘TABLE‘,@level1name=N‘T_hys_plan‘, @level2type=N‘COLUMN‘,@level2name=N‘hys‘
166 GO
167 EXEC sys.sp_addextendedproperty @name=N‘MS_Description‘, @value=N‘预约人‘ , @level0type=N‘SCHEMA‘,@level0name=N‘dbo‘, @level1type=N‘TABLE‘,@level1name=N‘T_hys_plan‘, @level2type=N‘COLUMN‘,@level2name=N‘yyr‘
168 GO
169 EXEC sys.sp_addextendedproperty @name=N‘MS_Description‘, @value=N‘预约部门‘ , @level0type=N‘SCHEMA‘,@level0name=N‘dbo‘, @level1type=N‘TABLE‘,@level1name=N‘T_hys_plan‘, @level2type=N‘COLUMN‘,@level2name=N‘yybm‘
170 GO
171 EXEC sys.sp_addextendedproperty @name=N‘MS_Description‘, @value=N‘会议主题‘ , @level0type=N‘SCHEMA‘,@level0name=N‘dbo‘, @level1type=N‘TABLE‘,@level1name=N‘T_hys_plan‘, @level2type=N‘COLUMN‘,@level2name=N‘hyzt‘
172 GO
173 EXEC sys.sp_addextendedproperty @name=N‘MS_Description‘, @value=N‘目前状态‘ , @level0type=N‘SCHEMA‘,@level0name=N‘dbo‘, @level1type=N‘TABLE‘,@level1name=N‘T_hys_plan‘, @level2type=N‘COLUMN‘,@level2name=N‘mqzt‘
174 GO
175 EXEC sys.sp_addextendedproperty @name=N‘MS_Description‘, @value=N‘操作密码‘ , @level0type=N‘SCHEMA‘,@level0name=N‘dbo‘, @level1type=N‘TABLE‘,@level1name=N‘T_hys_plan‘, @level2type=N‘COLUMN‘,@level2name=N‘lock_key‘
176 GO
177 EXEC sys.sp_addextendedproperty @name=N‘MS_Description‘, @value=N‘是否例会 0--不是例会,1--是例会‘ , @level0type=N‘SCHEMA‘,@level0name=N‘dbo‘, @level1type=N‘TABLE‘,@level1name=N‘T_hys_plan‘, @level2type=N‘COLUMN‘,@level2name=N‘flax_while‘
178 GO
179 EXEC sys.sp_addextendedproperty @name=N‘MS_Description‘, @value=N‘例会备注‘ , @level0type=N‘SCHEMA‘,@level0name=N‘dbo‘, @level1type=N‘TABLE‘,@level1name=N‘T_hys_plan‘, @level2type=N‘COLUMN‘,@level2name=N‘flax_bz‘
180 GO
181 EXEC sys.sp_addextendedproperty @name=N‘MS_Description‘, @value=N‘每周几‘ , @level0type=N‘SCHEMA‘,@level0name=N‘dbo‘, @level1type=N‘TABLE‘,@level1name=N‘T_hys_plan‘, @level2type=N‘COLUMN‘,@level2name=N‘zhou_x‘
182 GO
183 EXEC sys.sp_addextendedproperty @name=N‘MS_Description‘, @value=N‘每月几号‘ , @level0type=N‘SCHEMA‘,@level0name=N‘dbo‘, @level1type=N‘TABLE‘,@level1name=N‘T_hys_plan‘, @level2type=N‘COLUMN‘,@level2name=N‘yue_x‘
184 GO
185 EXEC sys.sp_addextendedproperty @name=N‘MS_Description‘, @value=N‘每天‘ , @level0type=N‘SCHEMA‘,@level0name=N‘dbo‘, @level1type=N‘TABLE‘,@level1name=N‘T_hys_plan‘, @level2type=N‘COLUMN‘,@level2name=N‘day_x‘
186 GO
187 EXEC sys.sp_addextendedproperty @name=N‘MS_Description‘, @value=N‘备注‘ , @level0type=N‘SCHEMA‘,@level0name=N‘dbo‘, @level1type=N‘TABLE‘,@level1name=N‘T_hys_plan‘, @level2type=N‘COLUMN‘,@level2name=N‘bz‘
188 GO
189 EXEC sys.sp_addextendedproperty @name=N‘MS_Description‘, @value=N‘标志‘ , @level0type=N‘SCHEMA‘,@level0name=N‘dbo‘, @level1type=N‘TABLE‘,@level1name=N‘T_hys_plan‘, @level2type=N‘COLUMN‘,@level2name=N‘flax‘
190 GO
191 /****** Object:  Table [dbo].[T_meetingroom]    Script Date: 07/13/2017 08:38:16 ******/
192 SET ANSI_NULLS ON
193 GO
194 SET QUOTED_IDENTIFIER ON
195 GO
196 CREATE TABLE [dbo].[T_meetingroom](
197     [id] [int] IDENTITY(1,1) NOT NULL,
198     [meetingroom] [nvarchar](50) NULL,
199  CONSTRAINT [PK_T_meetingroom] PRIMARY KEY CLUSTERED
200 (
201     [id] ASC
202 )WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
203 ) ON [PRIMARY]
204 GO
205 /****** Object:  Table [dbo].[T_time]    Script Date: 07/13/2017 08:38:16 ******/
206 SET ANSI_NULLS ON
207 GO
208 SET QUOTED_IDENTIFIER ON
209 GO
210 CREATE TABLE [dbo].[T_time](
211     [id] [int] IDENTITY(1,1) NOT NULL,
212     [timeContent] [nvarchar](50) NOT NULL,
213  CONSTRAINT [PK_T_time] PRIMARY KEY CLUSTERED
214 (
215     [id] ASC
216 )WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
217 ) ON [PRIMARY]
218 GO
219 /****** Object:  View [dbo].[T_meeting_plan]    Script Date: 07/13/2017 08:38:17 ******/
220 SET ANSI_NULLS ON
221 GO
222 SET QUOTED_IDENTIFIER ON
223 GO
224 CREATE VIEW [dbo].[T_meeting_plan]
225 AS
226 SELECT     id, add_time, adder, rq, time_begin, time_end, hys, yyr, yybm, hyzt, bz, mqzt, lock_key, flax_while, flax
227 FROM         dbo.T_hys_plan
228 WHERE     (flax_while = ‘0‘)
229 GO
230 EXEC sys.sp_addextendedproperty @name=N‘MS_DiagramPane1‘, @value=N‘[0E232FF0-B466-11cf-A24F-00AA00A3EFFF, 1.00]
231 Begin DesignProperties =
232    Begin PaneConfigurations =
233       Begin PaneConfiguration = 0
234          NumPanes = 4
235          Configuration = "(H (1[40] 4[20] 2[20] 3) )"
236       End
237       Begin PaneConfiguration = 1
238          NumPanes = 3
239          Configuration = "(H (1 [50] 4 [25] 3))"
240       End
241       Begin PaneConfiguration = 2
242          NumPanes = 3
243          Configuration = "(H (1 [50] 2 [25] 3))"
244       End
245       Begin PaneConfiguration = 3
246          NumPanes = 3
247          Configuration = "(H (4 [30] 2 [40] 3))"
248       End
249       Begin PaneConfiguration = 4
250          NumPanes = 2
251          Configuration = "(H (1 [56] 3))"
252       End
253       Begin PaneConfiguration = 5
254          NumPanes = 2
255          Configuration = "(H (2 [66] 3))"
256       End
257       Begin PaneConfiguration = 6
258          NumPanes = 2
259          Configuration = "(H (4 [50] 3))"
260       End
261       Begin PaneConfiguration = 7
262          NumPanes = 1
263          Configuration = "(V (3))"
264       End
265       Begin PaneConfiguration = 8
266          NumPanes = 3
267          Configuration = "(H (1[56] 4[18] 2) )"
268       End
269       Begin PaneConfiguration = 9
270          NumPanes = 2
271          Configuration = "(H (1 [75] 4))"
272       End
273       Begin PaneConfiguration = 10
274          NumPanes = 2
275          Configuration = "(H (1[66] 2) )"
276       End
277       Begin PaneConfiguration = 11
278          NumPanes = 2
279          Configuration = "(H (4 [60] 2))"
280       End
281       Begin PaneConfiguration = 12
282          NumPanes = 1
283          Configuration = "(H (1) )"
284       End
285       Begin PaneConfiguration = 13
286          NumPanes = 1
287          Configuration = "(V (4))"
288       End
289       Begin PaneConfiguration = 14
290          NumPanes = 1
291          Configuration = "(V (2))"
292       End
293       ActivePaneConfig = 0
294    End
295    Begin DiagramPane =
296       Begin Origin =
297          Top = 0
298          Left = 0
299       End
300       Begin Tables =
301          Begin Table = "T_hys_plan"
302             Begin Extent =
303                Top = 6
304                Left = 38
305                Bottom = 243
306                Right = 171
307             End
308             DisplayFlags = 280
309             TopColumn = 7
310          End
311       End
312    End
313    Begin SQLPane =
314    End
315    Begin DataPane =
316       Begin ParameterDefaults = ""
317       End
318    End
319    Begin CriteriaPane =
320       Begin ColumnWidths = 11
321          Column = 1440
322          Alias = 900
323          Table = 1170
324          Output = 720
325          Append = 1400
326          NewValue = 1170
327          SortType = 1350
328          SortOrder = 1410
329          GroupBy = 1350
330          Filter = 1350
331          Or = 1350
332          Or = 1350
333          Or = 1350
334       End
335    End
336 End
337 ‘ , @level0type=N‘SCHEMA‘,@level0name=N‘dbo‘, @level1type=N‘VIEW‘,@level1name=N‘T_meeting_plan‘
338 GO
339 EXEC sys.sp_addextendedproperty @name=N‘MS_DiagramPaneCount‘, @value=1 , @level0type=N‘SCHEMA‘,@level0name=N‘dbo‘, @level1type=N‘VIEW‘,@level1name=N‘T_meeting_plan‘
340 GO
341 /****** Object:  Default [DF_T_bm_bm_no]    Script Date: 07/13/2017 08:38:16 ******/
342 ALTER TABLE [dbo].[T_bm] ADD  CONSTRAINT [DF_T_bm_bm_no]  DEFAULT (‘‘) FOR [bm_no]
343 GO
344 /****** Object:  Default [DF_T_bm_bm_mc]    Script Date: 07/13/2017 08:38:16 ******/
345 ALTER TABLE [dbo].[T_bm] ADD  CONSTRAINT [DF_T_bm_bm_mc]  DEFAULT (‘‘) FOR [bm_mc]
346 GO
347 /****** Object:  Default [DF_T_bm_adder]    Script Date: 07/13/2017 08:38:16 ******/
348 ALTER TABLE [dbo].[T_bm] ADD  CONSTRAINT [DF_T_bm_adder]  DEFAULT (‘‘) FOR [adder]
349 GO
350 /****** Object:  Default [DF_T_bm_add_time]    Script Date: 07/13/2017 08:38:16 ******/
351 ALTER TABLE [dbo].[T_bm] ADD  CONSTRAINT [DF_T_bm_add_time]  DEFAULT (CONVERT([varchar](100),getdate(),(20))) FOR [add_time]
352 GO
353 /****** Object:  Default [DF_T_hys_add_time]    Script Date: 07/13/2017 08:38:16 ******/
354 ALTER TABLE [dbo].[T_hys_plan] ADD  CONSTRAINT [DF_T_hys_add_time]  DEFAULT (CONVERT([varchar](100),getdate(),(20))) FOR [add_time]
355 GO
356 /****** Object:  Default [DF_T_hys_adder]    Script Date: 07/13/2017 08:38:16 ******/
357 ALTER TABLE [dbo].[T_hys_plan] ADD  CONSTRAINT [DF_T_hys_adder]  DEFAULT (‘‘) FOR [adder]
358 GO
359 /****** Object:  Default [DF_T_hys_hys]    Script Date: 07/13/2017 08:38:16 ******/
360 ALTER TABLE [dbo].[T_hys_plan] ADD  CONSTRAINT [DF_T_hys_hys]  DEFAULT (‘‘) FOR [hys]
361 GO
362 /****** Object:  Default [DF_T_hys_yyr]    Script Date: 07/13/2017 08:38:16 ******/
363 ALTER TABLE [dbo].[T_hys_plan] ADD  CONSTRAINT [DF_T_hys_yyr]  DEFAULT (‘‘) FOR [yyr]
364 GO
365 /****** Object:  Default [DF_T_hys_yybm]    Script Date: 07/13/2017 08:38:16 ******/
366 ALTER TABLE [dbo].[T_hys_plan] ADD  CONSTRAINT [DF_T_hys_yybm]  DEFAULT (‘‘) FOR [yybm]
367 GO
368 /****** Object:  Default [DF_T_hys_hyzt]    Script Date: 07/13/2017 08:38:16 ******/
369 ALTER TABLE [dbo].[T_hys_plan] ADD  CONSTRAINT [DF_T_hys_hyzt]  DEFAULT (‘‘) FOR [hyzt]
370 GO
371 /****** Object:  Default [DF_T_hys_mqzt]    Script Date: 07/13/2017 08:38:16 ******/
372 ALTER TABLE [dbo].[T_hys_plan] ADD  CONSTRAINT [DF_T_hys_mqzt]  DEFAULT (‘‘) FOR [mqzt]
373 GO
374 /****** Object:  Default [DF_T_hys_lock_key]    Script Date: 07/13/2017 08:38:16 ******/
375 ALTER TABLE [dbo].[T_hys_plan] ADD  CONSTRAINT [DF_T_hys_lock_key]  DEFAULT (‘‘) FOR [lock_key]
376 GO
377 /****** Object:  Default [DF_T_hys_plan_flax_while]    Script Date: 07/13/2017 08:38:16 ******/
378 ALTER TABLE [dbo].[T_hys_plan] ADD  CONSTRAINT [DF_T_hys_plan_flax_while]  DEFAULT (‘‘) FOR [flax_while]
379 GO
380 /****** Object:  Default [DF_T_hys_plan_flax_bz]    Script Date: 07/13/2017 08:38:16 ******/
381 ALTER TABLE [dbo].[T_hys_plan] ADD  CONSTRAINT [DF_T_hys_plan_flax_bz]  DEFAULT (‘‘) FOR [flax_bz]
382 GO
383 /****** Object:  Default [DF_T_hys_plan_zhou_x]    Script Date: 07/13/2017 08:38:16 ******/
384 ALTER TABLE [dbo].[T_hys_plan] ADD  CONSTRAINT [DF_T_hys_plan_zhou_x]  DEFAULT (‘‘) FOR [zhou_x]
385 GO
386 /****** Object:  Default [DF_T_hys_plan_yue_x]    Script Date: 07/13/2017 08:38:16 ******/
387 ALTER TABLE [dbo].[T_hys_plan] ADD  CONSTRAINT [DF_T_hys_plan_yue_x]  DEFAULT (‘‘) FOR [yue_x]
388 GO
389 /****** Object:  Default [DF_T_hys_plan_day_x]    Script Date: 07/13/2017 08:38:16 ******/
390 ALTER TABLE [dbo].[T_hys_plan] ADD  CONSTRAINT [DF_T_hys_plan_day_x]  DEFAULT (‘‘) FOR [day_x]
391 GO
392 /****** Object:  Default [DF_T_hys_plan_bz]    Script Date: 07/13/2017 08:38:16 ******/
393 ALTER TABLE [dbo].[T_hys_plan] ADD  CONSTRAINT [DF_T_hys_plan_bz]  DEFAULT (‘‘) FOR [bz]
394 GO
395 /****** Object:  Default [DF_T_hys_plan_flax]    Script Date: 07/13/2017 08:38:16 ******/
396 ALTER TABLE [dbo].[T_hys_plan] ADD  CONSTRAINT [DF_T_hys_plan_flax]  DEFAULT (‘‘) FOR [flax]
397 GO
398 /****** Object:  Default [DF_T_kryy_plan_adder]    Script Date: 07/13/2017 08:38:16 ******/
399 ALTER TABLE [dbo].[T_kryy_plan] ADD  CONSTRAINT [DF_T_kryy_plan_adder]  DEFAULT (‘‘) FOR [adder]
400 GO
401 /****** Object:  Default [DF_T_kryy_plan_add_time]    Script Date: 07/13/2017 08:38:16 ******/
402 ALTER TABLE [dbo].[T_kryy_plan] ADD  CONSTRAINT [DF_T_kryy_plan_add_time]  DEFAULT (CONVERT([varchar](100),getdate(),(20))) FOR [add_time]
403 GO
404 /****** Object:  Default [DF_T_kryy_plan_rq]    Script Date: 07/13/2017 08:38:16 ******/
405 ALTER TABLE [dbo].[T_kryy_plan] ADD  CONSTRAINT [DF_T_kryy_plan_rq]  DEFAULT (‘‘) FOR [rq]
406 GO
407 /****** Object:  Default [DF_T_kryy_plan_sjd]    Script Date: 07/13/2017 08:38:16 ******/
408 ALTER TABLE [dbo].[T_kryy_plan] ADD  CONSTRAINT [DF_T_kryy_plan_sjd]  DEFAULT (‘‘) FOR [sjd]
409 GO
410 /****** Object:  Default [DF_T_kryy_plan_yyr]    Script Date: 07/13/2017 08:38:16 ******/
411 ALTER TABLE [dbo].[T_kryy_plan] ADD  CONSTRAINT [DF_T_kryy_plan_yyr]  DEFAULT (‘‘) FOR [yyr]
412 GO
413 /****** Object:  Default [DF_T_kryy_plan_yybm]    Script Date: 07/13/2017 08:38:16 ******/
414 ALTER TABLE [dbo].[T_kryy_plan] ADD  CONSTRAINT [DF_T_kryy_plan_yybm]  DEFAULT (‘‘) FOR [yybm]
415 GO
416 /****** Object:  Default [DF_T_kryy_plan_krxm]    Script Date: 07/13/2017 08:38:16 ******/
417 ALTER TABLE [dbo].[T_kryy_plan] ADD  CONSTRAINT [DF_T_kryy_plan_krxm]  DEFAULT (‘‘) FOR [krxm]
418 GO
419 /****** Object:  Default [DF_T_kryy_plan_krgs]    Script Date: 07/13/2017 08:38:16 ******/
420 ALTER TABLE [dbo].[T_kryy_plan] ADD  CONSTRAINT [DF_T_kryy_plan_krgs]  DEFAULT (‘‘) FOR [krgs]
421 GO
422 /****** Object:  Default [DF_T_kryy_plan_mqzt]    Script Date: 07/13/2017 08:38:16 ******/
423 ALTER TABLE [dbo].[T_kryy_plan] ADD  CONSTRAINT [DF_T_kryy_plan_mqzt]  DEFAULT (‘‘) FOR [mqzt]
424 GO
425 /****** Object:  Default [DF_T_kryy_plan_ztsj]    Script Date: 07/13/2017 08:38:16 ******/
426 ALTER TABLE [dbo].[T_kryy_plan] ADD  CONSTRAINT [DF_T_kryy_plan_ztsj]  DEFAULT (‘‘) FOR [ztsj]
427 GO
428 /****** Object:  Default [DF_T_kryy_plan_bz]    Script Date: 07/13/2017 08:38:16 ******/
429 ALTER TABLE [dbo].[T_kryy_plan] ADD  CONSTRAINT [DF_T_kryy_plan_bz]  DEFAULT (‘‘) FOR [bz]
430 GO
431 /****** Object:  Default [DF_T_room_room_id]    Script Date: 07/13/2017 08:38:16 ******/
432 ALTER TABLE [dbo].[T_room] ADD  CONSTRAINT [DF_T_room_room_id]  DEFAULT (‘‘) FOR [room_id]
433 GO
434 /****** Object:  Default [DF_T_room_room_mc]    Script Date: 07/13/2017 08:38:16 ******/
435 ALTER TABLE [dbo].[T_room] ADD  CONSTRAINT [DF_T_room_room_mc]  DEFAULT (‘‘) FOR [room_mc]
436 GO
437 /****** Object:  Default [DF_T_room_adder]    Script Date: 07/13/2017 08:38:16 ******/
438 ALTER TABLE [dbo].[T_room] ADD  CONSTRAINT [DF_T_room_adder]  DEFAULT (‘‘) FOR [adder]
439 GO
440 /****** Object:  Default [DF_T_room_add_time]    Script Date: 07/13/2017 08:38:16 ******/
441 ALTER TABLE [dbo].[T_room] ADD  CONSTRAINT [DF_T_room_add_time]  DEFAULT (CONVERT([varchar](100),getdate(),(20))) FOR [add_time]
442 GO
443 /****** Object:  Default [DF_T_userInfo_add_time]    Script Date: 07/13/2017 08:38:16 ******/
444 ALTER TABLE [dbo].[T_userInfo] ADD  CONSTRAINT [DF_T_userInfo_add_time]  DEFAULT (getdate()) FOR [add_time]
445 GO

T_bm:部门表

T_hys_plan:会议室预约详细表

T_room:会议室表

T_userInfo:用户表

时间: 2024-10-21 03:40:24

预约系统(一) 数据库设计的相关文章

公交车路线查询系统后台数据库设计--换乘算法改进与优化

在<查询算法>一文中已经实现了换乘算法,但是,使用存储过程InquiryT2查询从“东圃镇”到“车陂路口”的乘车路线时,发现居然用了5分钟才查找出结果,这样的效率显然不适合实际应用.因此,有必要对原有的换乘算法进行优化和改进.在本文中,将给出一种改进的换乘算法,相比原有的算法,改进后的算法功能更强,效率更优. 1. “压缩”RouteT0 假设RouteT0有以下几行 如下图所示,当查询S1到S4的二次换乘路线时,将会产生3×2×4=24个结果 从图中可以看出,第1段路线中的3条线路的起点和站

【机房收费系统】数据库设计

概述本文介绍基于机房收费系统  基本遵循三范式的数据库设计. 仅满足最基本功能需求.不包括额外的信息保存. 回想 关系模式设计的好坏直接影响到数据冗余度和数据一致性等问题. 由此我们有了一个评价指标.即范式. 第一范式:关系模式R的每一个关系r的属性值都是不可分的原子值 第二范式:关系模式R是1NF且每一个非主属性全然依赖于候选键 第三范式:关系模式R是1NF且每一个非主属性都不传递依赖于R的候选键 ER图 ER图转换成关系模式集的算法 步骤一(实体类型的转换) 将每一个实体类型转换成一个关系模

机房收费系统重构——数据库设计

终于,走到了机房收费系统重构的阶段-- 之前的一遍机房收费系统的数据库是用的给的那个,只是把每个表都看了一下,当时也没有学习数据库原理那本书,然后就没有深究-- 现在不一样了,我们进行机房收费系统重构,况且学习了数据库原理这本书,对数据库有了更深的认识.所以对于数据库要好好的设计,按照步骤走-- 数据库技术是信息资源管理最有效地手段.数据库设计是指对于一个给定的应用环境,构造最优的数据库模式,建立数据库及其应用系统,有效存储数据,满足用户信息要求和处理要求. 数据库的设计的步骤和各阶段的主要内容

网上外卖及订餐系统的数据库设计

背景:互联网越来越发达,宅男越来越宅,网上订餐送叫外卖的越来越多. 注:本文仅做后台数据库设计,不做系统功能设计. 一.数据库需求分析 1.用户分为游客.注册用户和管理员用户,只有登录用户才能进行网上订餐,游客仅能浏览餐厅及菜肴信息,只有管理员身份才能进行后台管理 2.一个餐厅设计一张菜单:一张订单对应一个送餐员,可以包含多个菜肴:一个客服管理员可以管理多张订单 3.每个菜肴从属于一个菜系,一个菜单,一个餐厅 4.一个用户可以选择多个菜肴,产生多个订单 5.一张菜单每次对应一个优惠活动 二.数据

基于SQLite的问卷调查系统的数据库设计

毕业设计写了一个基于Android的问卷调查系统,完成的只有离线部分,为了存储本地的一些数据设计了这个数据库.后来一个做Android开发的同学告诉我,Android项目一般不会把大量数据存储在本地.而在写毕业设计之前我几乎没有接触过Android开发,为了毕业设计,也只好硬着头皮这么做了,至于源码就不贴出来丢人了.这里主要介绍一下数据库的设计吧.希望和有兴趣的人共同讨论学习,本人对数据库比较感兴趣,虽然现在做的工作跟数据库不相关. 首先问卷调查系统得想办法把问卷存储下来,我的做法是用代码解析按

【转】多语言系统的数据库设计

首先我们需要确认我们要做的系统,多语言到底是要做多少种语言,以后会不会要求增加更多的语言.比如我们做一个给中国大陆和纽伦新港使用的系统,可以确定的语言就是简体中文.繁体中文和英语,而且可以确定以后也不会增加语言.确定以后是否需要增加语言这一点很重要,决定了我们在数据库设计时,是否需要考虑多语上的扩展性. 先说下在数据库设计时,可以有以下方案实现多语: 一.为每个多语字段建立对应语言的字段列. 比如我们有一个客户表,记录了客户Id.客户名称.客户地址.客户电话等,其中客户名称和客户地址是多语的,而

火车票订票系统的数据库设计与实现(某某乐后端实习面试题)

目的:设计一个车票的数据库,完成一些基本的查询.增删功能. 数据表结构分析: 各个字段分析: 基本数据库.表的建立,数据录入: 复杂查询的实现简要分析. 1 数据库结构分析: 1.1 客户表 目的:查询客户的所有信息. 输出字段:身份证号(主键).姓名.用户名.联系电话.籍贯.类型(学生还是普通) 1.2 订票单表 目的:查询某一客户订单票的信息 输入in:姓名 输出:订单编号,订票时间,乘车日期,订票数量 1.3车票表 输出:车次,出发站,目的站,座位类型,座位号,车票价格,发车时间,到站时间

录播教室预约系统(一)-数据库表

数据库用的是mssql2005. 数据库表如下: USE [RoomSchedule] GO /****** 对象: Table [dbo].[ClassRoom] 脚本日期: 02/07/2015 22:41:56 ******/ SET ANSI_NULLS ON GO SET QUOTED_IDENTIFIER ON GO CREATE TABLE [dbo].[ClassRoom]( [Id] [int] IDENTITY(1000,1) NOT NULL, [RoomName] [nv

数据库设计中主键问题

转自: http://www.jb51.net/article/40933.htm 数据库主键在数据库中占有重要地位.主键的选取策略决定了系统是否可靠.易用.高效.本文探讨了数据库设计过程当中常见的主键选取策略,并剖析了其做主键的优缺点,提出了相应的解决问题的方法 在基于关系型数据库设计时候,通常要为每张表指定一个主键,所谓主键就是能够唯一标识表中某一行记录的属性或属性组,一个表只能有一个主键,但可以有多个候选索引.因为主键可以唯一标识某一行记录,所以可以确保执行数据更新.删除.修改时不出现错误

功能教室预约系统开源下载(c#源码)

这个功能教室预约系统是帮朋友做的,最近没事整理出来,供大家参考,本系统为CS结构,服务器端客户端程序. 数据基于mssql2005  .net2.0版本 通讯框架为networkcomms2.3.1 录播教室预约系统序言 录播教室预约系统(一)-数据库表 录播教室预约系统(二)-服务器端与数据库的交互 录播教室预约系统(三)-DepTable表[普通表] 录播教室预约系统(四)-ClassRoom表[带有外键的表] 录播教室预约系统(五)-用户登陆 录播教室预约系统(六)-注册新用户 录播教室预