/****** Object:  Table [dbo].[AdminUser]    Script Date: 05/08/2013 12:59:47 ******/
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF_AdminUser_classID]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[AdminUser] DROP CONSTRAINT [DF_AdminUser_classID]
END
GO
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF_AdminUser_groupID]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[AdminUser] DROP CONSTRAINT [DF_AdminUser_groupID]
END
GO
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF_AdminUser_postIF]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[AdminUser] DROP CONSTRAINT [DF_AdminUser_postIF]
END
GO
IF  EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[AdminUser]') AND type in (N'U'))
DROP TABLE [dbo].[AdminUser]
GO
/****** Object:  Table [dbo].[ads]    Script Date: 05/08/2013 12:59:47 ******/
IF  EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[ads]') AND type in (N'U'))
DROP TABLE [dbo].[ads]
GO
/****** Object:  Table [dbo].[cerpic]    Script Date: 05/08/2013 12:59:47 ******/
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF__cerpic__cerName__07F6335A]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[cerpic] DROP CONSTRAINT [DF__cerpic__cerName__07F6335A]
END
GO
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF__cerpic__fromDate__08EA5793]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[cerpic] DROP CONSTRAINT [DF__cerpic__fromDate__08EA5793]
END
GO
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF__cerpic__toDate__09DE7BCC]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[cerpic] DROP CONSTRAINT [DF__cerpic__toDate__09DE7BCC]
END
GO
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF__cerpic__postDate__0AD2A005]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[cerpic] DROP CONSTRAINT [DF__cerpic__postDate__0AD2A005]
END
GO
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF__cerpic__adminID__0BC6C43E]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[cerpic] DROP CONSTRAINT [DF__cerpic__adminID__0BC6C43E]
END
GO
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF__cerpic__adminDat__0CBAE877]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[cerpic] DROP CONSTRAINT [DF__cerpic__adminDat__0CBAE877]
END
GO
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF__cerpic__adminIP__0DAF0CB0]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[cerpic] DROP CONSTRAINT [DF__cerpic__adminIP__0DAF0CB0]
END
GO
IF  EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[cerpic]') AND type in (N'U'))
DROP TABLE [dbo].[cerpic]
GO
/****** Object:  Table [dbo].[classAdmin]    Script Date: 05/08/2013 12:59:47 ******/
IF  EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[classAdmin]') AND type in (N'U'))
DROP TABLE [dbo].[classAdmin]
GO
/****** Object:  Table [dbo].[feedbackBook]    Script Date: 05/08/2013 12:59:47 ******/
IF  EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[feedbackBook]') AND type in (N'U'))
DROP TABLE [dbo].[feedbackBook]
GO
/****** Object:  Table [dbo].[linkXabara]    Script Date: 05/08/2013 12:59:47 ******/
IF  EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[linkXabara]') AND type in (N'U'))
DROP TABLE [dbo].[linkXabara]
GO
/****** Object:  Table [dbo].[logLogin]    Script Date: 05/08/2013 12:59:47 ******/
IF  EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[logLogin]') AND type in (N'U'))
DROP TABLE [dbo].[logLogin]
GO
/****** Object:  Table [dbo].[mailSend]    Script Date: 05/08/2013 12:59:48 ******/
IF  EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[mailSend]') AND type in (N'U'))
DROP TABLE [dbo].[mailSend]
GO
/****** Object:  Table [dbo].[moneybankremit]    Script Date: 05/08/2013 12:59:48 ******/
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF__moneybank__remit__20C1E124]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[moneybankremit] DROP CONSTRAINT [DF__moneybank__remit__20C1E124]
END
GO
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF__moneybank__admin__21B6055D]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[moneybankremit] DROP CONSTRAINT [DF__moneybank__admin__21B6055D]
END
GO
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF__moneybank__admin__22AA2996]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[moneybankremit] DROP CONSTRAINT [DF__moneybank__admin__22AA2996]
END
GO
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF__moneybank__admin__239E4DCF]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[moneybankremit] DROP CONSTRAINT [DF__moneybank__admin__239E4DCF]
END
GO
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF__moneybank__postD__24927208]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[moneybankremit] DROP CONSTRAINT [DF__moneybank__postD__24927208]
END
GO
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF__moneybank__postI__25869641]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[moneybankremit] DROP CONSTRAINT [DF__moneybank__postI__25869641]
END
GO
IF  EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[moneybankremit]') AND type in (N'U'))
DROP TABLE [dbo].[moneybankremit]
GO
/****** Object:  Table [dbo].[moneyDetail]    Script Date: 05/08/2013 12:59:48 ******/
IF  EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[moneyDetail]') AND type in (N'U'))
DROP TABLE [dbo].[moneyDetail]
GO
/****** Object:  Table [dbo].[NewsTree]    Script Date: 05/08/2013 12:59:48 ******/
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF_NewsTree_treeDel]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[NewsTree] DROP CONSTRAINT [DF_NewsTree_treeDel]
END
GO
IF  EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[NewsTree]') AND type in (N'U'))
DROP TABLE [dbo].[NewsTree]
GO
/****** Object:  Table [dbo].[NewsXabara]    Script Date: 05/08/2013 12:59:48 ******/
IF  EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[NewsXabara]') AND type in (N'U'))
DROP TABLE [dbo].[NewsXabara]
GO
/****** Object:  Table [dbo].[onlineorder]    Script Date: 05/08/2013 12:59:48 ******/
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF__onlineorder__ts__34C8D9D1]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[onlineorder] DROP CONSTRAINT [DF__onlineorder__ts__34C8D9D1]
END
GO
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF__onlineorder__pID__35BCFE0A]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[onlineorder] DROP CONSTRAINT [DF__onlineorder__pID__35BCFE0A]
END
GO
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF__onlineorder__cID__36B12243]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[onlineorder] DROP CONSTRAINT [DF__onlineorder__cID__36B12243]
END
GO
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF__onlineorder__aID__37A5467C]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[onlineorder] DROP CONSTRAINT [DF__onlineorder__aID__37A5467C]
END
GO
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF__onlineord__teach__38996AB5]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[onlineorder] DROP CONSTRAINT [DF__onlineord__teach__38996AB5]
END
GO
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF__onlineord__yourE__398D8EEE]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[onlineorder] DROP CONSTRAINT [DF__onlineord__yourE__398D8EEE]
END
GO
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF__onlineord__yourT__3A81B327]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[onlineorder] DROP CONSTRAINT [DF__onlineord__yourT__3A81B327]
END
GO
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF__onlineord__userI__3B75D760]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[onlineorder] DROP CONSTRAINT [DF__onlineord__userI__3B75D760]
END
GO
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF__onlineord__admin__3C69FB99]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[onlineorder] DROP CONSTRAINT [DF__onlineord__admin__3C69FB99]
END
GO
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF__onlineord__admin__3D5E1FD2]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[onlineorder] DROP CONSTRAINT [DF__onlineord__admin__3D5E1FD2]
END
GO
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF__onlineord__admin__3E52440B]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[onlineorder] DROP CONSTRAINT [DF__onlineord__admin__3E52440B]
END
GO
IF  EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[onlineorder]') AND type in (N'U'))
DROP TABLE [dbo].[onlineorder]
GO
/****** Object:  Table [dbo].[paybank]    Script Date: 05/08/2013 12:59:48 ******/
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF__paybank__adminID__403A8C7D]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[paybank] DROP CONSTRAINT [DF__paybank__adminID__403A8C7D]
END
GO
IF  EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[paybank]') AND type in (N'U'))
DROP TABLE [dbo].[paybank]
GO
/****** Object:  Table [dbo].[selectarea]    Script Date: 05/08/2013 12:59:48 ******/
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF__selectare__areaP__4222D4EF]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[selectarea] DROP CONSTRAINT [DF__selectare__areaP__4222D4EF]
END
GO
IF  EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[selectarea]') AND type in (N'U'))
DROP TABLE [dbo].[selectarea]
GO
/****** Object:  Table [dbo].[selectcity]    Script Date: 05/08/2013 12:59:48 ******/
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF__selectcit__cityP__440B1D61]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[selectcity] DROP CONSTRAINT [DF__selectcit__cityP__440B1D61]
END
GO
IF  EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[selectcity]') AND type in (N'U'))
DROP TABLE [dbo].[selectcity]
GO
/****** Object:  Table [dbo].[selectprovince]    Script Date: 05/08/2013 12:59:48 ******/
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF__selectpro__provi__45F365D3]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[selectprovince] DROP CONSTRAINT [DF__selectpro__provi__45F365D3]
END
GO
IF  EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[selectprovince]') AND type in (N'U'))
DROP TABLE [dbo].[selectprovince]
GO
/****** Object:  Table [dbo].[studentinfo]    Script Date: 05/08/2013 12:59:48 ******/
IF  EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[studentinfo]') AND type in (N'U'))
DROP TABLE [dbo].[studentinfo]
GO
/****** Object:  Table [dbo].[teacherinfo]    Script Date: 05/08/2013 12:59:48 ******/
IF  EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[teacherinfo]') AND type in (N'U'))
DROP TABLE [dbo].[teacherinfo]
GO
/****** Object:  Table [dbo].[ts]    Script Date: 05/08/2013 12:59:48 ******/
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF__ts__guestDate__49C3F6B7]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[ts] DROP CONSTRAINT [DF__ts__guestDate__49C3F6B7]
END
GO
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF__ts__guestIP__4AB81AF0]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[ts] DROP CONSTRAINT [DF__ts__guestIP__4AB81AF0]
END
GO
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF__ts__myDate__4BAC3F29]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[ts] DROP CONSTRAINT [DF__ts__myDate__4BAC3F29]
END
GO
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF__ts__myIP__4CA06362]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[ts] DROP CONSTRAINT [DF__ts__myIP__4CA06362]
END
GO
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF__ts__postID__4D94879B]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[ts] DROP CONSTRAINT [DF__ts__postID__4D94879B]
END
GO
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF__ts__postDate__4E88ABD4]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[ts] DROP CONSTRAINT [DF__ts__postDate__4E88ABD4]
END
GO
IF  EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[DF__ts__postIP__4F7CD00D]') AND type = 'D')
BEGIN
ALTER TABLE [dbo].[ts] DROP CONSTRAINT [DF__ts__postIP__4F7CD00D]
END
GO
IF  EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[ts]') AND type in (N'U'))
DROP TABLE [dbo].[ts]
GO
/****** Object:  Table [dbo].[upFileName]    Script Date: 05/08/2013 12:59:49 ******/
IF  EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[upFileName]') AND type in (N'U'))
DROP TABLE [dbo].[upFileName]
GO
/****** Object:  Table [dbo].[XabaraUser]    Script Date: 05/08/2013 12:59:49 ******/
IF  EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[XabaraUser]') AND type in (N'U'))
DROP TABLE [dbo].[XabaraUser]
GO
/****** Object:  Table [dbo].[XabaraUser]    Script Date: 05/08/2013 12:59:49 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
IF NOT EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[XabaraUser]') AND type in (N'U'))
BEGIN
CREATE TABLE [dbo].[XabaraUser](
	[Uid] [bigint] IDENTITY(1,1) NOT NULL,
	[userCardID] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[userID] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NULL,
	[cardID] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NULL,
	[qqID] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NULL,
	[alipayID] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NULL,
	[userEmail] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[userEmailDate] [datetime] NULL,
	[userLevel] [int] NOT NULL,
	[userLevelDate] [datetime] NULL,
	[jiFen] [bigint] NOT NULL,
	[userPW] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[userPayPW] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NULL,
	[webName] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NULL,
	[userName] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NULL,
	[userSex] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NULL,
	[userBirthday] [datetime] NULL,
	[userProvince] [bigint] NOT NULL,
	[userCity] [bigint] NOT NULL,
	[userArea] [bigint] NOT NULL,
	[userAdd] [nvarchar](255) COLLATE Chinese_PRC_CI_AS NULL,
	[userZip] [nvarchar](20) COLLATE Chinese_PRC_CI_AS NULL,
	[userTel] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NULL,
	[userMobile] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NULL,
	[userFax] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NULL,
	[userQQ] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NULL,
	[userWW] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NULL,
	[userIdCard] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NULL,
	[userImg] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NULL,
	[loginFlag] [smallint] NOT NULL,
	[loginNum] [bigint] NOT NULL,
	[loginDate] [datetime] NOT NULL,
	[loginIP] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[sessionError] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[postDate] [datetime] NOT NULL,
 CONSTRAINT [PK_XabaraUser] PRIMARY KEY CLUSTERED 
(
	[Uid] ASC
)WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
) ON [PRIMARY]
END
GO
IF NOT EXISTS (SELECT * FROM sys.indexes WHERE object_id = OBJECT_ID(N'[dbo].[XabaraUser]') AND name = N'IX_XabaraUser')
CREATE NONCLUSTERED INDEX [IX_XabaraUser] ON [dbo].[XabaraUser] 
(
	[alipayID] ASC,
	[jiFen] ASC,
	[qqID] ASC,
	[userBirthday] ASC,
	[userCardID] ASC,
	[userSex] ASC,
	[userEmail] ASC,
	[userID] ASC,
	[userIdCard] ASC,
	[userMobile] ASC,
	[userLevel] ASC
)WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, SORT_IN_TEMPDB = OFF, IGNORE_DUP_KEY = OFF, DROP_EXISTING = OFF, ONLINE = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
GO
/****** Object:  Table [dbo].[upFileName]    Script Date: 05/08/2013 12:59:49 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
IF NOT EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[upFileName]') AND type in (N'U'))
BEGIN
CREATE TABLE [dbo].[upFileName](
	[Fid] [bigint] IDENTITY(1,1) NOT NULL,
	[fileID] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[fileTable] [nvarchar](20) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[fileFlag] [nvarchar](10) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[fileName] [nvarchar](30) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[fileContent] [nvarchar](max) COLLATE Chinese_PRC_CI_AS NULL,
	[PostDate] [datetime] NOT NULL,
	[AdminIP] [nvarchar](20) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[AdminID] [nvarchar](20) COLLATE Chinese_PRC_CI_AS NOT NULL,
 CONSTRAINT [PK_upFileName] PRIMARY KEY CLUSTERED 
(
	[Fid] ASC
)WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
) ON [PRIMARY] TEXTIMAGE_ON [PRIMARY]
END
GO
IF NOT EXISTS (SELECT * FROM sys.indexes WHERE object_id = OBJECT_ID(N'[dbo].[upFileName]') AND name = N'IX_upFileName')
CREATE NONCLUSTERED INDEX [IX_upFileName] ON [dbo].[upFileName] 
(
	[fileFlag] ASC,
	[fileTable] ASC
)WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, SORT_IN_TEMPDB = OFF, IGNORE_DUP_KEY = OFF, DROP_EXISTING = OFF, ONLINE = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
GO
/****** Object:  Table [dbo].[ts]    Script Date: 05/08/2013 12:59:48 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
IF NOT EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[ts]') AND type in (N'U'))
BEGIN
CREATE TABLE [dbo].[ts](
	[id] [bigint] IDENTITY(1,1) NOT NULL,
	[tID] [bigint] NOT NULL,
	[sID] [bigint] NOT NULL,
	[guestAppraise] [nvarchar](max) COLLATE Chinese_PRC_CI_AS NULL,
	[guestDate] [datetime] NULL CONSTRAINT [DF__ts__guestDate__49C3F6B7]  DEFAULT (NULL),
	[guestIP] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NULL CONSTRAINT [DF__ts__guestIP__4AB81AF0]  DEFAULT (NULL),
	[myCommentate] [nvarchar](max) COLLATE Chinese_PRC_CI_AS NULL,
	[myDate] [datetime] NULL CONSTRAINT [DF__ts__myDate__4BAC3F29]  DEFAULT (NULL),
	[myIP] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NULL CONSTRAINT [DF__ts__myIP__4CA06362]  DEFAULT (NULL),
	[postID] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NULL CONSTRAINT [DF__ts__postID__4D94879B]  DEFAULT (NULL),
	[postDate] [datetime] NULL CONSTRAINT [DF__ts__postDate__4E88ABD4]  DEFAULT (NULL),
	[postIP] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NULL CONSTRAINT [DF__ts__postIP__4F7CD00D]  DEFAULT (NULL),
 CONSTRAINT [PK_ts_id] PRIMARY KEY CLUSTERED 
(
	[id] ASC
)WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
) ON [PRIMARY] TEXTIMAGE_ON [PRIMARY]
END
GO
IF NOT EXISTS (SELECT * FROM sys.indexes WHERE object_id = OBJECT_ID(N'[dbo].[ts]') AND name = N'IX_ts')
CREATE NONCLUSTERED INDEX [IX_ts] ON [dbo].[ts] 
(
	[sID] ASC,
	[tID] ASC,
	[postID] ASC
)WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, SORT_IN_TEMPDB = OFF, IGNORE_DUP_KEY = OFF, DROP_EXISTING = OFF, ONLINE = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
GO
IF NOT EXISTS (SELECT * FROM ::fn_listextendedproperty(N'MS_SSMA_SOURCE' , N'SCHEMA',N'dbo', N'TABLE',N'ts', NULL,NULL))
EXEC sys.sp_addextendedproperty @name=N'MS_SSMA_SOURCE', @value=N'jiajiao.ts' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'ts'
GO
/****** Object:  Table [dbo].[teacherinfo]    Script Date: 05/08/2013 12:59:48 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
IF NOT EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[teacherinfo]') AND type in (N'U'))
BEGIN
CREATE TABLE [dbo].[teacherinfo](
	[tID] [bigint] IDENTITY(1,1) NOT NULL,
	[uID] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[nowEdu] [bigint] NOT NULL,
	[nowWork] [bigint] NOT NULL,
	[provinceID] [bigint] NOT NULL,
	[cityID] [bigint] NOT NULL,
	[areaID] [bigint] NOT NULL,
	[studySchool] [nvarchar](100) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[studyProfession] [nvarchar](100) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[teachAge] [bigint] NOT NULL,
	[gradeID] [bigint] NOT NULL,
	[teachTypeID] [nvarchar](100) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[openClass] [nvarchar](10) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[classNums] [nvarchar](20) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[aboutME] [nvarchar](max) COLLATE Chinese_PRC_CI_AS NULL,
	[teachRoad] [nvarchar](max) COLLATE Chinese_PRC_CI_AS NULL,
	[teachStudyIDs] [nvarchar](100) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[studyTimeIDs] [nvarchar](100) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[studyTimeInfo] [nvarchar](max) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[payMoney] [float] NOT NULL,
	[payBit] [bigint] NOT NULL,
	[adBeginDate] [datetime] NOT NULL,
	[adEndDate] [datetime] NOT NULL,
	[workFlag] [int] NOT NULL,
	[workDate] [datetime] NOT NULL,
	[readNums] [bigint] NOT NULL,
	[postDate] [datetime] NOT NULL,
	[postIP] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NOT NULL,
 CONSTRAINT [PK_teacherinfo_tID] PRIMARY KEY CLUSTERED 
(
	[tID] ASC
)WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
) ON [PRIMARY] TEXTIMAGE_ON [PRIMARY]
END
GO
IF NOT EXISTS (SELECT * FROM sys.indexes WHERE object_id = OBJECT_ID(N'[dbo].[teacherinfo]') AND name = N'IX_teacherinfo')
CREATE NONCLUSTERED INDEX [IX_teacherinfo] ON [dbo].[teacherinfo] 
(
	[adBeginDate] ASC,
	[adEndDate] ASC,
	[areaID] ASC,
	[cityID] ASC,
	[gradeID] ASC,
	[openClass] ASC,
	[provinceID] ASC,
	[studyProfession] ASC,
	[teachStudyIDs] ASC,
	[teachTypeID] ASC,
	[uID] ASC,
	[workFlag] ASC
)WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, SORT_IN_TEMPDB = OFF, IGNORE_DUP_KEY = OFF, DROP_EXISTING = OFF, ONLINE = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
GO
IF NOT EXISTS (SELECT * FROM ::fn_listextendedproperty(N'MS_SSMA_SOURCE' , N'SCHEMA',N'dbo', N'TABLE',N'teacherinfo', NULL,NULL))
EXEC sys.sp_addextendedproperty @name=N'MS_SSMA_SOURCE', @value=N'jiajiao.teacherinfo' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'teacherinfo'
GO
/****** Object:  Table [dbo].[studentinfo]    Script Date: 05/08/2013 12:59:48 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
IF NOT EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[studentinfo]') AND type in (N'U'))
BEGIN
CREATE TABLE [dbo].[studentinfo](
	[sID] [bigint] IDENTITY(1,1) NOT NULL,
	[uID] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[gradeID] [bigint] NOT NULL,
	[GradeIDs] [nvarchar](100) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[myGradeId] [bigint] NOT NULL,
	[provinceID] [bigint] NOT NULL,
	[cityID] [bigint] NOT NULL,
	[areaID] [bigint] NOT NULL,
	[schoolName] [nvarchar](30) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[sexMy] [nvarchar](3) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[studyTypeID] [bigint] NOT NULL,
	[myInfo] [nvarchar](max) COLLATE Chinese_PRC_CI_AS NULL,
	[sexTeacher] [nvarchar](10) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[teacherTypeIDs] [nvarchar](100) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[teachStudyIDs] [nvarchar](100) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[teachInfo] [nvarchar](max) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[teachWeek] [bigint] NOT NULL,
	[studyTimeIDs] [nvarchar](100) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[studyInfo] [nvarchar](max) COLLATE Chinese_PRC_CI_AS NULL,
	[payMoney] [float] NOT NULL,
	[payBit] [bigint] NOT NULL,
	[carMoney] [nvarchar](30) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[adBeginDate] [datetime] NOT NULL,
	[adEndDate] [datetime] NOT NULL,
	[workFlag] [int] NOT NULL,
	[workDate] [datetime] NOT NULL,
	[readNums] [bigint] NOT NULL,
	[postDate] [datetime] NOT NULL,
	[postIP] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NOT NULL,
 CONSTRAINT [PK_studentinfo_sID] PRIMARY KEY CLUSTERED 
(
	[sID] ASC
)WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
) ON [PRIMARY] TEXTIMAGE_ON [PRIMARY]
END
GO
IF NOT EXISTS (SELECT * FROM sys.indexes WHERE object_id = OBJECT_ID(N'[dbo].[studentinfo]') AND name = N'IX_studentinfo')
CREATE NONCLUSTERED INDEX [IX_studentinfo] ON [dbo].[studentinfo] 
(
	[adBeginDate] ASC,
	[adEndDate] ASC,
	[areaID] ASC,
	[cityID] ASC,
	[gradeID] ASC,
	[GradeIDs] ASC,
	[myGradeId] ASC,
	[provinceID] ASC,
	[studyTypeID] ASC,
	[teacherTypeIDs] ASC,
	[teachStudyIDs] ASC,
	[workFlag] ASC,
	[uID] ASC
)WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, SORT_IN_TEMPDB = OFF, IGNORE_DUP_KEY = OFF, DROP_EXISTING = OFF, ONLINE = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
GO
IF NOT EXISTS (SELECT * FROM ::fn_listextendedproperty(N'MS_SSMA_SOURCE' , N'SCHEMA',N'dbo', N'TABLE',N'studentinfo', NULL,NULL))
EXEC sys.sp_addextendedproperty @name=N'MS_SSMA_SOURCE', @value=N'jiajiao.studentinfo' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'studentinfo'
GO
/****** Object:  Table [dbo].[selectprovince]    Script Date: 05/08/2013 12:59:48 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
IF NOT EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[selectprovince]') AND type in (N'U'))
BEGIN
CREATE TABLE [dbo].[selectprovince](
	[id] [bigint] IDENTITY(1,1) NOT NULL,
	[provinceID] [bigint] NOT NULL,
	[provincePY] [nvarchar](2) COLLATE Chinese_PRC_CI_AS NULL CONSTRAINT [DF__selectpro__provi__45F365D3]  DEFAULT (NULL),
	[provinceTxt] [nvarchar](max) COLLATE Chinese_PRC_CI_AS NOT NULL,
 CONSTRAINT [PK_selectprovince_id] PRIMARY KEY CLUSTERED 
(
	[id] ASC
)WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
) ON [PRIMARY] TEXTIMAGE_ON [PRIMARY]
END
GO
IF NOT EXISTS (SELECT * FROM sys.indexes WHERE object_id = OBJECT_ID(N'[dbo].[selectprovince]') AND name = N'IX_selectprovince')
CREATE NONCLUSTERED INDEX [IX_selectprovince] ON [dbo].[selectprovince] 
(
	[provinceID] ASC,
	[provincePY] ASC
)WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, SORT_IN_TEMPDB = OFF, IGNORE_DUP_KEY = OFF, DROP_EXISTING = OFF, ONLINE = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
GO
IF NOT EXISTS (SELECT * FROM ::fn_listextendedproperty(N'MS_SSMA_SOURCE' , N'SCHEMA',N'dbo', N'TABLE',N'selectprovince', NULL,NULL))
EXEC sys.sp_addextendedproperty @name=N'MS_SSMA_SOURCE', @value=N'jiajiao.selectprovince' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'selectprovince'
GO
/****** Object:  Table [dbo].[selectcity]    Script Date: 05/08/2013 12:59:48 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
IF NOT EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[selectcity]') AND type in (N'U'))
BEGIN
CREATE TABLE [dbo].[selectcity](
	[id] [bigint] IDENTITY(1,1) NOT NULL,
	[cityID] [bigint] NOT NULL,
	[cityPY] [nvarchar](1) COLLATE Chinese_PRC_CI_AS NULL CONSTRAINT [DF__selectcit__cityP__440B1D61]  DEFAULT (NULL),
	[cityTxt] [nvarchar](255) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[cFather] [bigint] NOT NULL,
 CONSTRAINT [PK_selectcity_id] PRIMARY KEY CLUSTERED 
(
	[id] ASC
)WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
) ON [PRIMARY]
END
GO
IF NOT EXISTS (SELECT * FROM sys.indexes WHERE object_id = OBJECT_ID(N'[dbo].[selectcity]') AND name = N'IX_selectcity')
CREATE NONCLUSTERED INDEX [IX_selectcity] ON [dbo].[selectcity] 
(
	[cityPY] ASC,
	[cFather] ASC,
	[cityID] ASC
)WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, SORT_IN_TEMPDB = OFF, IGNORE_DUP_KEY = OFF, DROP_EXISTING = OFF, ONLINE = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
GO
IF NOT EXISTS (SELECT * FROM ::fn_listextendedproperty(N'MS_SSMA_SOURCE' , N'SCHEMA',N'dbo', N'TABLE',N'selectcity', NULL,NULL))
EXEC sys.sp_addextendedproperty @name=N'MS_SSMA_SOURCE', @value=N'jiajiao.selectcity' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'selectcity'
GO
/****** Object:  Table [dbo].[selectarea]    Script Date: 05/08/2013 12:59:48 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
IF NOT EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[selectarea]') AND type in (N'U'))
BEGIN
CREATE TABLE [dbo].[selectarea](
	[id] [bigint] IDENTITY(1,1) NOT NULL,
	[areaID] [bigint] NOT NULL,
	[areaPY] [nvarchar](1) COLLATE Chinese_PRC_CI_AS NULL CONSTRAINT [DF__selectare__areaP__4222D4EF]  DEFAULT (NULL),
	[areaTxt] [nvarchar](max) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[aFather] [bigint] NOT NULL,
 CONSTRAINT [PK_selectarea_id] PRIMARY KEY CLUSTERED 
(
	[id] ASC
)WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
) ON [PRIMARY] TEXTIMAGE_ON [PRIMARY]
END
GO
IF NOT EXISTS (SELECT * FROM sys.indexes WHERE object_id = OBJECT_ID(N'[dbo].[selectarea]') AND name = N'IX_selectarea')
CREATE NONCLUSTERED INDEX [IX_selectarea] ON [dbo].[selectarea] 
(
	[areaPY] ASC,
	[areaID] ASC
)WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, SORT_IN_TEMPDB = OFF, IGNORE_DUP_KEY = OFF, DROP_EXISTING = OFF, ONLINE = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
GO
IF NOT EXISTS (SELECT * FROM ::fn_listextendedproperty(N'MS_SSMA_SOURCE' , N'SCHEMA',N'dbo', N'TABLE',N'selectarea', NULL,NULL))
EXEC sys.sp_addextendedproperty @name=N'MS_SSMA_SOURCE', @value=N'jiajiao.selectarea' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'selectarea'
GO
/****** Object:  Table [dbo].[paybank]    Script Date: 05/08/2013 12:59:48 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
IF NOT EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[paybank]') AND type in (N'U'))
BEGIN
CREATE TABLE [dbo].[paybank](
	[id] [bigint] IDENTITY(1,1) NOT NULL,
	[bankName] [nvarchar](100) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[bankAdd] [nvarchar](100) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[bankUserName] [nvarchar](100) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[bankAccount] [nvarchar](100) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[adminID] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NULL CONSTRAINT [DF__paybank__adminID__403A8C7D]  DEFAULT (NULL),
	[postDate] [datetime] NOT NULL,
	[postIP] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NOT NULL,
 CONSTRAINT [PK_paybank_id] PRIMARY KEY CLUSTERED 
(
	[id] ASC
)WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
) ON [PRIMARY]
END
GO
IF NOT EXISTS (SELECT * FROM ::fn_listextendedproperty(N'MS_SSMA_SOURCE' , N'SCHEMA',N'dbo', N'TABLE',N'paybank', NULL,NULL))
EXEC sys.sp_addextendedproperty @name=N'MS_SSMA_SOURCE', @value=N'jiajiao.paybank' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'paybank'
GO
/****** Object:  Table [dbo].[onlineorder]    Script Date: 05/08/2013 12:59:48 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
SET ANSI_PADDING ON
GO
IF NOT EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[onlineorder]') AND type in (N'U'))
BEGIN
CREATE TABLE [dbo].[onlineorder](
	[id] [bigint] IDENTITY(1,1) NOT NULL,
	[ts] [varchar](1) COLLATE Chinese_PRC_CI_AS NULL CONSTRAINT [DF__onlineorder__ts__34C8D9D1]  DEFAULT (NULL),
	[relatingID] [bigint] NOT NULL,
	[pID] [bigint] NULL CONSTRAINT [DF__onlineorder__pID__35BCFE0A]  DEFAULT (NULL),
	[cID] [bigint] NULL CONSTRAINT [DF__onlineorder__cID__36B12243]  DEFAULT (NULL),
	[aID] [bigint] NULL CONSTRAINT [DF__onlineorder__aID__37A5467C]  DEFAULT (NULL),
	[teachIDs] [nvarchar](max) COLLATE Chinese_PRC_CI_AS NULL CONSTRAINT [DF__onlineord__teach__38996AB5]  DEFAULT (NULL),
	[yourName] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[yourEmail] [nvarchar](max) COLLATE Chinese_PRC_CI_AS NULL CONSTRAINT [DF__onlineord__yourE__398D8EEE]  DEFAULT (NULL),
	[yourTel] [nvarchar](20) COLLATE Chinese_PRC_CI_AS NULL CONSTRAINT [DF__onlineord__yourT__3A81B327]  DEFAULT (NULL),
	[yourMobile] [nvarchar](20) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[youAddress] [nvarchar](max) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[guestBook] [nvarchar](max) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[flagID] [int] NOT NULL,
	[postIP] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[postDate] [datetime] NOT NULL,
	[userID] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NULL CONSTRAINT [DF__onlineord__userI__3B75D760]  DEFAULT (NULL),
	[adminIP] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NULL CONSTRAINT [DF__onlineord__admin__3C69FB99]  DEFAULT (NULL),
	[adminDate] [datetime] NULL CONSTRAINT [DF__onlineord__admin__3D5E1FD2]  DEFAULT (NULL),
	[adminID] [nvarchar](20) COLLATE Chinese_PRC_CI_AS NULL CONSTRAINT [DF__onlineord__admin__3E52440B]  DEFAULT (NULL),
 CONSTRAINT [PK_onlineorder_id] PRIMARY KEY CLUSTERED 
(
	[id] ASC
)WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
) ON [PRIMARY] TEXTIMAGE_ON [PRIMARY]
END
GO
SET ANSI_PADDING OFF
GO
IF NOT EXISTS (SELECT * FROM sys.indexes WHERE object_id = OBJECT_ID(N'[dbo].[onlineorder]') AND name = N'IX_onlineorder')
CREATE NONCLUSTERED INDEX [IX_onlineorder] ON [dbo].[onlineorder] 
(
	[ts] ASC,
	[flagID] ASC,
	[pID] ASC,
	[cID] ASC,
	[aID] ASC,
	[relatingID] ASC
)WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, SORT_IN_TEMPDB = OFF, IGNORE_DUP_KEY = OFF, DROP_EXISTING = OFF, ONLINE = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
GO
IF NOT EXISTS (SELECT * FROM ::fn_listextendedproperty(N'MS_SSMA_SOURCE' , N'SCHEMA',N'dbo', N'TABLE',N'onlineorder', NULL,NULL))
EXEC sys.sp_addextendedproperty @name=N'MS_SSMA_SOURCE', @value=N'jiajiao.onlineorder' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'onlineorder'
GO
/****** Object:  Table [dbo].[NewsXabara]    Script Date: 05/08/2013 12:59:48 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
IF NOT EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[NewsXabara]') AND type in (N'U'))
BEGIN
CREATE TABLE [dbo].[NewsXabara](
	[Nid] [bigint] IDENTITY(1,1) NOT NULL,
	[upNameID] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[treeTid] [bigint] NOT NULL,
	[upPreImg] [nvarchar](30) COLLATE Chinese_PRC_CI_AS NULL,
	[NewTitle] [nvarchar](200) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[NewsAuthor] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NULL,
	[newsFrom] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NULL,
	[linkHttp] [nvarchar](max) COLLATE Chinese_PRC_CI_AS NULL,
	[titleFontB] [smallint] NULL,
	[titleFontC] [nvarchar](10) COLLATE Chinese_PRC_CI_AS NULL,
	[keyWord] [nvarchar](255) COLLATE Chinese_PRC_CI_AS NULL,
	[NewContent] [ntext] COLLATE Chinese_PRC_CI_AS NOT NULL,
	[ReadNums] [bigint] NOT NULL,
	[TopDate] [datetime] NOT NULL,
	[PostDate] [datetime] NOT NULL,
	[adminPass] [smallint] NOT NULL,
	[AdminIP] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[AdminID] [nvarchar](20) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[userID] [nvarchar](20) COLLATE Chinese_PRC_CI_AS NULL,
 CONSTRAINT [PK_NewsXabara] PRIMARY KEY CLUSTERED 
(
	[Nid] ASC
)WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
) ON [PRIMARY] TEXTIMAGE_ON [PRIMARY]
END
GO
IF NOT EXISTS (SELECT * FROM sys.indexes WHERE object_id = OBJECT_ID(N'[dbo].[NewsXabara]') AND name = N'IX_NewsXabara')
CREATE NONCLUSTERED INDEX [IX_NewsXabara] ON [dbo].[NewsXabara] 
(
	[TopDate] DESC,
	[adminPass] ASC,
	[NewTitle] ASC,
	[treeTid] ASC,
	[upNameID] ASC,
	[upPreImg] ASC,
	[userID] ASC
)WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, SORT_IN_TEMPDB = OFF, IGNORE_DUP_KEY = OFF, DROP_EXISTING = OFF, ONLINE = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
GO
/****** Object:  Table [dbo].[NewsTree]    Script Date: 05/08/2013 12:59:48 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
IF NOT EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[NewsTree]') AND type in (N'U'))
BEGIN
CREATE TABLE [dbo].[NewsTree](
	[Tid] [bigint] IDENTITY(1,1) NOT NULL,
	[fnID] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NULL,
	[TreeID] [bigint] NOT NULL,
	[ListID] [int] NOT NULL,
	[idLayerStr] [nvarchar](max) COLLATE Chinese_PRC_CI_AS NULL,
	[ids] [nvarchar](max) COLLATE Chinese_PRC_CI_AS NULL,
	[groupExe] [nvarchar](max) COLLATE Chinese_PRC_CI_AS NULL,
	[TreeName] [nvarchar](100) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[treeNameTxt] [nvarchar](max) COLLATE Chinese_PRC_CI_AS NULL,
	[TreeNameImg] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NULL,
	[TreeType] [nvarchar](20) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[TreeUrl] [nvarchar](255) COLLATE Chinese_PRC_CI_AS NULL,
	[treeAdmin] [int] NULL,
	[treeDel] [int] NULL CONSTRAINT [DF_NewsTree_treeDel]  DEFAULT ((0)),
	[PostDate] [datetime] NOT NULL,
	[AdminIP] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[AdminID] [nvarchar](20) COLLATE Chinese_PRC_CI_AS NOT NULL,
 CONSTRAINT [PK_NewsTree] PRIMARY KEY CLUSTERED 
(
	[Tid] ASC
)WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
) ON [PRIMARY] TEXTIMAGE_ON [PRIMARY]
END
GO
IF NOT EXISTS (SELECT * FROM sys.indexes WHERE object_id = OBJECT_ID(N'[dbo].[NewsTree]') AND name = N'IX_NewsTree')
CREATE NONCLUSTERED INDEX [IX_NewsTree] ON [dbo].[NewsTree] 
(
	[fnID] ASC,
	[ListID] ASC,
	[TreeID] ASC,
	[TreeType] ASC,
	[treeAdmin] ASC
)WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, SORT_IN_TEMPDB = OFF, IGNORE_DUP_KEY = OFF, DROP_EXISTING = OFF, ONLINE = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
GO
/****** Object:  Table [dbo].[moneyDetail]    Script Date: 05/08/2013 12:59:48 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
IF NOT EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[moneyDetail]') AND type in (N'U'))
BEGIN
CREATE TABLE [dbo].[moneyDetail](
	[dID] [bigint] IDENTITY(1,1) NOT NULL,
	[uID] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[orderID] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[addMoney] [float] NOT NULL,
	[moneyFee] [float] NULL,
	[subtractMoney] [float] NOT NULL,
	[nowMoney] [float] NOT NULL,
	[buyMoney] [float] NOT NULL,
	[moneyInfo] [ntext] COLLATE Chinese_PRC_CI_AS NOT NULL,
	[postDate] [datetime] NOT NULL,
	[postIP] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[adminID] [nvarchar](30) COLLATE Chinese_PRC_CI_AS NULL,
 CONSTRAINT [PK_moneyDetail] PRIMARY KEY CLUSTERED 
(
	[dID] ASC
)WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
) ON [PRIMARY] TEXTIMAGE_ON [PRIMARY]
END
GO
IF NOT EXISTS (SELECT * FROM sys.indexes WHERE object_id = OBJECT_ID(N'[dbo].[moneyDetail]') AND name = N'IX_moneyDetail')
CREATE NONCLUSTERED INDEX [IX_moneyDetail] ON [dbo].[moneyDetail] 
(
	[orderID] ASC,
	[uID] ASC
)WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, SORT_IN_TEMPDB = OFF, IGNORE_DUP_KEY = OFF, DROP_EXISTING = OFF, ONLINE = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
GO
/****** Object:  Table [dbo].[moneybankremit]    Script Date: 05/08/2013 12:59:48 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
IF NOT EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[moneybankremit]') AND type in (N'U'))
BEGIN
CREATE TABLE [dbo].[moneybankremit](
	[rID] [bigint] IDENTITY(1,1) NOT NULL,
	[uID] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[rndID] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[remitName] [nvarchar](100) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[remitBank] [nvarchar](100) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[remitMoney] [float] NOT NULL,
	[remitDate] [datetime] NOT NULL,
	[remitType] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[remitInfo] [nvarchar](max) COLLATE Chinese_PRC_CI_AS NULL,
	[remitImg] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NULL CONSTRAINT [DF__moneybank__remit__20C1E124]  DEFAULT (NULL),
	[adminPass] [int] NOT NULL,
	[adminID] [nvarchar](20) COLLATE Chinese_PRC_CI_AS NULL CONSTRAINT [DF__moneybank__admin__21B6055D]  DEFAULT (NULL),
	[adminDate] [datetime] NULL CONSTRAINT [DF__moneybank__admin__22AA2996]  DEFAULT (NULL),
	[adminIP] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NULL CONSTRAINT [DF__moneybank__admin__239E4DCF]  DEFAULT (NULL),
	[postDate] [datetime] NULL CONSTRAINT [DF__moneybank__postD__24927208]  DEFAULT (NULL),
	[postIP] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NULL CONSTRAINT [DF__moneybank__postI__25869641]  DEFAULT (NULL),
 CONSTRAINT [PK_moneybankremit_rID] PRIMARY KEY CLUSTERED 
(
	[rID] ASC
)WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
) ON [PRIMARY] TEXTIMAGE_ON [PRIMARY]
END
GO
IF NOT EXISTS (SELECT * FROM sys.indexes WHERE object_id = OBJECT_ID(N'[dbo].[moneybankremit]') AND name = N'IX_moneybankremit')
CREATE NONCLUSTERED INDEX [IX_moneybankremit] ON [dbo].[moneybankremit] 
(
	[rndID] ASC,
	[uID] ASC,
	[remitMoney] ASC,
	[adminPass] ASC
)WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, SORT_IN_TEMPDB = OFF, IGNORE_DUP_KEY = OFF, DROP_EXISTING = OFF, ONLINE = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
GO
IF NOT EXISTS (SELECT * FROM ::fn_listextendedproperty(N'MS_SSMA_SOURCE' , N'SCHEMA',N'dbo', N'TABLE',N'moneybankremit', NULL,NULL))
EXEC sys.sp_addextendedproperty @name=N'MS_SSMA_SOURCE', @value=N'jiajiao.moneybankremit' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'moneybankremit'
GO
/****** Object:  Table [dbo].[mailSend]    Script Date: 05/08/2013 12:59:48 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
IF NOT EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[mailSend]') AND type in (N'U'))
BEGIN
CREATE TABLE [dbo].[mailSend](
	[mID] [bigint] IDENTITY(1,1) NOT NULL,
	[uID] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[userType] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[sendOrderBy] [int] NOT NULL,
	[email] [nvarchar](max) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[mailTitle] [nvarchar](100) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[mailContent] [text] COLLATE Chinese_PRC_CI_AS NOT NULL,
	[postDate] [datetime] NOT NULL,
	[postIP] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[flagID] [int] NOT NULL,
	[sendDate] [datetime] NULL,
	[sendIP] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NULL,
 CONSTRAINT [PK_mailSend_1] PRIMARY KEY CLUSTERED 
(
	[mID] ASC
)WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
) ON [PRIMARY] TEXTIMAGE_ON [PRIMARY]
END
GO
IF NOT EXISTS (SELECT * FROM sys.indexes WHERE object_id = OBJECT_ID(N'[dbo].[mailSend]') AND name = N'IX_mailSend')
CREATE NONCLUSTERED INDEX [IX_mailSend] ON [dbo].[mailSend] 
(
	[sendOrderBy] ASC,
	[flagID] ASC
)WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, SORT_IN_TEMPDB = OFF, IGNORE_DUP_KEY = OFF, DROP_EXISTING = OFF, ONLINE = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
GO
/****** Object:  Table [dbo].[logLogin]    Script Date: 05/08/2013 12:59:47 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
IF NOT EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[logLogin]') AND type in (N'U'))
BEGIN
CREATE TABLE [dbo].[logLogin](
	[id] [bigint] IDENTITY(1,1) NOT NULL,
	[userID] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[userType] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[loginIP] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[loginDate] [datetime] NOT NULL,
	[exeTitle] [nvarchar](100) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[exeUrl] [ntext] COLLATE Chinese_PRC_CI_AS NULL,
 CONSTRAINT [PK_logLogin] PRIMARY KEY CLUSTERED 
(
	[id] DESC
)WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
) ON [PRIMARY] TEXTIMAGE_ON [PRIMARY]
END
GO
IF NOT EXISTS (SELECT * FROM sys.indexes WHERE object_id = OBJECT_ID(N'[dbo].[logLogin]') AND name = N'IX_logLogin')
CREATE NONCLUSTERED INDEX [IX_logLogin] ON [dbo].[logLogin] 
(
	[userID] ASC,
	[userType] ASC
)WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, SORT_IN_TEMPDB = OFF, IGNORE_DUP_KEY = OFF, DROP_EXISTING = OFF, ONLINE = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
GO
/****** Object:  Table [dbo].[linkXabara]    Script Date: 05/08/2013 12:59:47 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
IF NOT EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[linkXabara]') AND type in (N'U'))
BEGIN
CREATE TABLE [dbo].[linkXabara](
	[lid] [int] IDENTITY(1,1) NOT NULL,
	[listID] [int] NULL,
	[classID] [int] NOT NULL,
	[uploadFile] [nvarchar](30) COLLATE Chinese_PRC_CI_AS NULL,
	[linkName] [nvarchar](100) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[linkURL] [nvarchar](100) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[AdminID] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[postDate] [datetime] NOT NULL,
	[postIP] [nvarchar](20) COLLATE Chinese_PRC_CI_AS NOT NULL,
 CONSTRAINT [PK_linkXabara] PRIMARY KEY CLUSTERED 
(
	[lid] ASC
)WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
) ON [PRIMARY]
END
GO
IF NOT EXISTS (SELECT * FROM sys.indexes WHERE object_id = OBJECT_ID(N'[dbo].[linkXabara]') AND name = N'IX_linkXabara')
CREATE NONCLUSTERED INDEX [IX_linkXabara] ON [dbo].[linkXabara] 
(
	[classID] ASC,
	[listID] ASC,
	[uploadFile] ASC
)WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, SORT_IN_TEMPDB = OFF, IGNORE_DUP_KEY = OFF, DROP_EXISTING = OFF, ONLINE = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
GO
/****** Object:  Table [dbo].[feedbackBook]    Script Date: 05/08/2013 12:59:47 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
IF NOT EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[feedbackBook]') AND type in (N'U'))
BEGIN
CREATE TABLE [dbo].[feedbackBook](
	[id] [int] IDENTITY(1,1) NOT NULL,
	[treeID] [bigint] NOT NULL,
	[webName] [nvarchar](20) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[email] [nvarchar](30) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[fromWhere] [nvarchar](20) COLLATE Chinese_PRC_CI_AS NULL,
	[tel] [nvarchar](15) COLLATE Chinese_PRC_CI_AS NULL,
	[mobile] [nvarchar](11) COLLATE Chinese_PRC_CI_AS NULL,
	[webHttp] [nvarchar](255) COLLATE Chinese_PRC_CI_AS NULL,
	[yourAdd] [nvarchar](255) COLLATE Chinese_PRC_CI_AS NULL,
	[yourTitle] [nvarchar](255) COLLATE Chinese_PRC_CI_AS NULL,
	[yourContent] [ntext] COLLATE Chinese_PRC_CI_AS NOT NULL,
	[adminContent] [ntext] COLLATE Chinese_PRC_CI_AS NULL,
	[postDate] [datetime] NOT NULL,
	[postIP] [nvarchar](20) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[adminID] [nvarchar](20) COLLATE Chinese_PRC_CI_AS NULL,
	[adminDate] [datetime] NULL,
	[adminIP] [nvarchar](20) COLLATE Chinese_PRC_CI_AS NULL,
 CONSTRAINT [PK_feedbackBook] PRIMARY KEY CLUSTERED 
(
	[id] ASC
)WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
) ON [PRIMARY] TEXTIMAGE_ON [PRIMARY]
END
GO
IF NOT EXISTS (SELECT * FROM sys.indexes WHERE object_id = OBJECT_ID(N'[dbo].[feedbackBook]') AND name = N'IX_feedbackBook')
CREATE NONCLUSTERED INDEX [IX_feedbackBook] ON [dbo].[feedbackBook] 
(
	[treeID] ASC
)WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, SORT_IN_TEMPDB = OFF, IGNORE_DUP_KEY = OFF, DROP_EXISTING = OFF, ONLINE = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
GO
/****** Object:  Table [dbo].[classAdmin]    Script Date: 05/08/2013 12:59:47 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
IF NOT EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[classAdmin]') AND type in (N'U'))
BEGIN
CREATE TABLE [dbo].[classAdmin](
	[isFlag] [int] NOT NULL,
	[listClass] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[listID] [int] NOT NULL,
	[className] [nvarchar](30) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[classCode] [nvarchar](20) COLLATE Chinese_PRC_CI_AS NOT NULL
) ON [PRIMARY]
END
GO
IF NOT EXISTS (SELECT * FROM sys.indexes WHERE object_id = OBJECT_ID(N'[dbo].[classAdmin]') AND name = N'IX_classAdmin')
CREATE NONCLUSTERED INDEX [IX_classAdmin] ON [dbo].[classAdmin] 
(
	[isFlag] ASC,
	[listID] ASC,
	[listClass] ASC
)WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, SORT_IN_TEMPDB = OFF, IGNORE_DUP_KEY = OFF, DROP_EXISTING = OFF, ONLINE = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
GO
/****** Object:  Table [dbo].[cerpic]    Script Date: 05/08/2013 12:59:47 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
SET ANSI_PADDING ON
GO
IF NOT EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[cerpic]') AND type in (N'U'))
BEGIN
CREATE TABLE [dbo].[cerpic](
	[id] [bigint] IDENTITY(1,1) NOT NULL,
	[picType] [bigint] NOT NULL,
	[cerName] [varchar](20) COLLATE Chinese_PRC_CI_AS NULL CONSTRAINT [DF__cerpic__cerName__07F6335A]  DEFAULT (NULL),
	[picName] [varchar](50) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[fromDate] [datetime] NULL CONSTRAINT [DF__cerpic__fromDate__08EA5793]  DEFAULT (NULL),
	[toDate] [datetime] NULL CONSTRAINT [DF__cerpic__toDate__09DE7BCC]  DEFAULT (NULL),
	[postID] [varchar](50) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[postDate] [datetime] NULL CONSTRAINT [DF__cerpic__postDate__0AD2A005]  DEFAULT (NULL),
	[postIP] [varchar](50) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[flagID] [int] NOT NULL,
	[viewID] [int] NOT NULL,
	[adminID] [varchar](50) COLLATE Chinese_PRC_CI_AS NULL CONSTRAINT [DF__cerpic__adminID__0BC6C43E]  DEFAULT (NULL),
	[adminDate] [datetime] NULL CONSTRAINT [DF__cerpic__adminDat__0CBAE877]  DEFAULT (NULL),
	[adminIP] [varchar](50) COLLATE Chinese_PRC_CI_AS NULL CONSTRAINT [DF__cerpic__adminIP__0DAF0CB0]  DEFAULT (NULL),
 CONSTRAINT [PK_cerpic_id] PRIMARY KEY CLUSTERED 
(
	[id] ASC
)WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
) ON [PRIMARY]
END
GO
SET ANSI_PADDING OFF
GO
IF NOT EXISTS (SELECT * FROM sys.indexes WHERE object_id = OBJECT_ID(N'[dbo].[cerpic]') AND name = N'IX_cerpic')
CREATE NONCLUSTERED INDEX [IX_cerpic] ON [dbo].[cerpic] 
(
	[flagID] ASC,
	[picType] ASC,
	[postID] ASC,
	[viewID] ASC,
	[fromDate] ASC,
	[toDate] ASC
)WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, SORT_IN_TEMPDB = OFF, IGNORE_DUP_KEY = OFF, DROP_EXISTING = OFF, ONLINE = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
GO
IF NOT EXISTS (SELECT * FROM ::fn_listextendedproperty(N'MS_SSMA_SOURCE' , N'SCHEMA',N'dbo', N'TABLE',N'cerpic', NULL,NULL))
EXEC sys.sp_addextendedproperty @name=N'MS_SSMA_SOURCE', @value=N'jiajiao.cerpic' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'cerpic'
GO
/****** Object:  Table [dbo].[ads]    Script Date: 05/08/2013 12:59:47 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
IF NOT EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[ads]') AND type in (N'U'))
BEGIN
CREATE TABLE [dbo].[ads](
	[aID] [bigint] IDENTITY(1,1) NOT NULL,
	[classID] [bigint] NOT NULL,
	[adW] [int] NOT NULL,
	[adH] [int] NOT NULL,
	[adImg] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NULL,
	[adHttp] [nvarchar](max) COLLATE Chinese_PRC_CI_AS NULL,
	[adCode] [ntext] COLLATE Chinese_PRC_CI_AS NULL,
	[starDate] [datetime] NOT NULL,
	[stopDate] [datetime] NOT NULL,
	[postDate] [datetime] NOT NULL,
	[postIP] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[adminID] [nvarchar](20) COLLATE Chinese_PRC_CI_AS NOT NULL,
 CONSTRAINT [PK_ads] PRIMARY KEY CLUSTERED 
(
	[aID] ASC
)WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
) ON [PRIMARY] TEXTIMAGE_ON [PRIMARY]
END
GO
IF NOT EXISTS (SELECT * FROM sys.indexes WHERE object_id = OBJECT_ID(N'[dbo].[ads]') AND name = N'IX_ads')
CREATE NONCLUSTERED INDEX [IX_ads] ON [dbo].[ads] 
(
	[adH] ASC,
	[adW] ASC,
	[classID] ASC,
	[starDate] ASC,
	[stopDate] ASC
)WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, SORT_IN_TEMPDB = OFF, IGNORE_DUP_KEY = OFF, DROP_EXISTING = OFF, ONLINE = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
GO
/****** Object:  Table [dbo].[AdminUser]    Script Date: 05/08/2013 12:59:47 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
IF NOT EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[AdminUser]') AND type in (N'U'))
BEGIN
CREATE TABLE [dbo].[AdminUser](
	[Uid] [bigint] IDENTITY(1,1) NOT NULL,
	[userId] [nvarchar](20) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[cityID] [bigint] NULL,
	[classID] [bigint] NOT NULL CONSTRAINT [DF_AdminUser_classID]  DEFAULT ((0)),
	[groupID] [bigint] NULL CONSTRAINT [DF_AdminUser_groupID]  DEFAULT ((0)),
	[newsIDs] [nvarchar](max) COLLATE Chinese_PRC_CI_AS NULL,
	[helpIDs] [nvarchar](max) COLLATE Chinese_PRC_CI_AS NULL,
	[UserAdmin] [nvarchar](max) COLLATE Chinese_PRC_CI_AS NULL,
	[UserName] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[userEmail] [nvarchar](200) COLLATE Chinese_PRC_CI_AS NULL,
	[userTel] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NULL,
	[userMobile] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NULL,
	[userQQ] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NULL,
	[UserPW] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[SessionError] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NOT NULL,
	[loginFlag] [int] NOT NULL,
	[LoginNum] [bigint] NOT NULL,
	[postIF] [int] NOT NULL CONSTRAINT [DF_AdminUser_postIF]  DEFAULT ((1)),
	[RegDate] [datetime] NOT NULL,
	[LoginDate] [datetime] NOT NULL,
	[LoginIP] [nvarchar](50) COLLATE Chinese_PRC_CI_AS NOT NULL,
 CONSTRAINT [PK_AdminUser_1] PRIMARY KEY CLUSTERED 
(
	[Uid] ASC
)WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
) ON [PRIMARY] TEXTIMAGE_ON [PRIMARY]
END
GO
IF NOT EXISTS (SELECT * FROM sys.indexes WHERE object_id = OBJECT_ID(N'[dbo].[AdminUser]') AND name = N'IX_AdminUser')
CREATE NONCLUSTERED INDEX [IX_AdminUser] ON [dbo].[AdminUser] 
(
	[cityID] ASC,
	[classID] ASC,
	[groupID] ASC,
	[loginFlag] ASC,
	[SessionError] ASC,
	[userId] ASC,
	[UserPW] ASC,
	[LoginDate] DESC
)WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, SORT_IN_TEMPDB = OFF, IGNORE_DUP_KEY = OFF, DROP_EXISTING = OFF, ONLINE = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
GO