
/****** 对象:  Table [dbo].[ShopNum1_SurveyTheme]    脚本日期: 10/02/2009 19:02:58 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_SurveyTheme](
	[Guid] [uniqueidentifier] NOT NULL,
	[Title] [nvarchar](100) NULL,
	[StartTime] [datetime] NULL,
	[EndTime] [datetime] NULL,
	[SimplyOrMultiCheck] [int] NULL,
	[Static] [nvarchar](250) NULL,
	[Count] [int] NULL CONSTRAINT [DF_ShopNum1_SurveyTheme_Count]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_SurveyTheme] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
/****** 对象:  Table [dbo].[ShopNum1_ProductAttribute]    脚本日期: 10/02/2009 19:01:39 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_ProductAttribute](
	[Guid] [uniqueidentifier] NOT NULL,
	[Name] [nvarchar](50) NOT NULL,
	[InputType] [int] NOT NULL,
	[IsMultiSelect] [int] NOT NULL,
	[AttrValue] [ntext] NULL,
	[OrderId] [int] NOT NULL,
	[IsSearch] [int] NOT NULL,
	[IsRelated] [int] NOT NULL,
	[ProductTypeGuid] [uniqueidentifier] NOT NULL,
	[AttributeGroup] [nvarchar](100) NULL CONSTRAINT [DF_ShopNum1_ProductAttribute_AttributeGroup]  DEFAULT (NULL),
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_ProductAttribute_IsDeleted]  DEFAULT ((0)),
	[IsDownLoad] [int] NOT NULL CONSTRAINT [DF_ShopNum1_ProductAttribute_IsDownLoad]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_ProductAttribute] PRIMARY KEY CLUSTERED 
(
	[Guid] 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]
GO
/****** 对象:  Table [dbo].[ShopNum1_GuidInfoProduct]    脚本日期: 10/02/2009 18:57:53 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_GuidInfoProduct](
	[GuidInfoGuid] [uniqueidentifier] NOT NULL,
	[ProductGuid] [uniqueidentifier] NOT NULL,
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL
) ON [PRIMARY]
GO
/****** 对象:  Table [dbo].[ShopNum1_Help]    脚本日期: 10/02/2009 18:57:57 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_Help](
	[Guid] [uniqueidentifier] NOT NULL,
	[Title] [nvarchar](50) NOT NULL,
	[HelpTypeGuid] [uniqueidentifier] NOT NULL,
	[Remark] [ntext] NOT NULL,
	[OrderID] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Help_OrderID]  DEFAULT ((0)),
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Help_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_Help] PRIMARY KEY CLUSTERED 
(
	[Guid] 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]
GO
/****** 对象:  Table [dbo].[ShopNum1_Supplier]    脚本日期: 10/02/2009 19:02:52 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_Supplier](
	[Guid] [uniqueidentifier] NOT NULL,
	[Name] [nvarchar](50) NOT NULL,
	[Address] [nvarchar](150) NOT NULL,
	[Contact] [nvarchar](50) NOT NULL,
	[ContactTel] [nvarchar](50) NOT NULL,
	[Fax] [nvarchar](50) NULL,
	[Site] [nvarchar](50) NOT NULL,
	[CompanyLogo] [nvarchar](50) NULL,
	[Email] [nvarchar](50) NOT NULL,
	[PrimeProducts] [nvarchar](300) NOT NULL,
	[BusinessCulture] [nvarchar](200) NULL,
	[BusinessEntity] [nvarchar](50) NULL,
	[CompanyInfo] [ntext] NOT NULL,
	[Remark] [nvarchar](200) NOT NULL,
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Supplier_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_Supplier] PRIMARY KEY CLUSTERED 
(
	[Guid] 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]
GO
/****** 对象:  Table [dbo].[ShopNum1_MemberMessage]    脚本日期: 10/02/2009 18:59:19 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_MemberMessage](
	[Guid] [uniqueidentifier] NOT NULL,
	[MemLoginID] [nvarchar](50) NOT NULL,
	[LoginID] [nvarchar](50) NOT NULL,
	[ReplyContent] [ntext] NULL,
	[ReplyTime] [datetime] NULL,
	[IsRead] [int] NOT NULL CONSTRAINT [DF_ShopNum1_MemberMessage_IsRead]  DEFAULT ((0)),
	[SendTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_MemberMessage_IsDeleted]  DEFAULT ((0)),
	[MessageInfoGuid] [uniqueidentifier] NOT NULL,
 CONSTRAINT [PK_ShopNum1_MemberMessage] PRIMARY KEY CLUSTERED 
(
	[Guid] 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]
GO
/****** 对象:  Table [dbo].[ShopNum1_AdPosition]    脚本日期: 10/02/2009 18:55:12 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_AdPosition](
	[Guid] [uniqueidentifier] NOT NULL,
	[Name] [nvarchar](50) NOT NULL,
	[AdWidth] [int] NOT NULL CONSTRAINT [DF_ShopNum1_AdPosition_AdWidth]  DEFAULT ((0)),
	[AdHeight] [int] NOT NULL CONSTRAINT [DF_ShopNum1_AdPosition_AdHeight]  DEFAULT ((0)),
	[Memo] [ntext] NOT NULL,
	[TemplateCode] [nvarchar](4000) NULL,
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_AdPosition_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_AdPosition] PRIMARY KEY CLUSTERED 
(
	[Guid] 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]
GO
/****** 对象:  Table [dbo].[ShopNum1_MemberAssignGroup]    脚本日期: 10/02/2009 18:59:06 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_MemberAssignGroup](
	[Guid] [uniqueidentifier] NOT NULL,
	[MemLoginID] [nvarchar](50) NOT NULL,
	[MemberGroupGuid] [uniqueidentifier] NOT NULL,
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
 CONSTRAINT [PK_ShopNum1_MemberAssignGroup] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
/****** 对象:  Table [dbo].[ShopNum1_UserMessage]    脚本日期: 10/02/2009 19:03:19 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_UserMessage](
	[Guid] [uniqueidentifier] NOT NULL,
	[MemLoginID] [nvarchar](50) NOT NULL,
	[LoginID] [nvarchar](50) NOT NULL,
	[ReplyContent] [ntext] NULL,
	[ReplyTime] [datetime] NULL CONSTRAINT [DF_ShopNum1_UserMessage_ReplyTime]  DEFAULT (NULL),
	[IsRead] [int] NOT NULL CONSTRAINT [DF_ShopNum1_UserMessage_IsRead]  DEFAULT ((0)),
	[SendTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_UserMessage_IsDeleted]  DEFAULT ((0)),
	[MessageInfoGuid] [uniqueidentifier] NOT NULL,
 CONSTRAINT [PK_ShopNum1_UserMessage] PRIMARY KEY CLUSTERED 
(
	[Guid] 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]
GO
/****** 对象:  Table [dbo].[ShopNum1_SurveyOption]    脚本日期: 10/02/2009 19:02:55 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_SurveyOption](
	[Guid] [uniqueidentifier] NOT NULL,
	[SurveyGuid] [nvarchar](50) NOT NULL,
	[Name] [nvarchar](50) NULL,
	[Count] [int] NULL,
	[Order] [int] NULL,
 CONSTRAINT [PK_ShopNum1_SurveyOption] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
/****** 对象:  Table [dbo].[ShopNum1_ProductComment]    脚本日期: 10/02/2009 19:01:56 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_ProductComment](
	[Guid] [uniqueidentifier] NOT NULL,
	[ProductGuid] [uniqueidentifier] NOT NULL,
	[MemLoginID] [nvarchar](50) NULL,
	[Title] [nvarchar](200) NULL,
	[Rank] [int] NOT NULL,
	[SendTime] [datetime] NOT NULL,
	[Content] [ntext] NULL,
	[IPAddress] [nvarchar](50) NOT NULL,
	[ReplyUser] [nvarchar](50) NULL,
	[ReplyTime] [datetime] NULL,
	[ReplyContent] [ntext] NULL,
	[IsAudit] [int] NOT NULL CONSTRAINT [DF_ShopNum1_ProductComment_IsAudit]  DEFAULT ((0)),
	[IsReply] [int] NOT NULL CONSTRAINT [DF_ShopNum1_ProductComment_IsReply]  DEFAULT ((0)),
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_ProductComment_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_ProductComment] PRIMARY KEY CLUSTERED 
(
	[Guid] 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]
GO
/****** 对象:  Table [dbo].[ShopNum1_Payment]    脚本日期: 10/02/2009 19:01:06 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_Payment](
	[Guid] [uniqueidentifier] NOT NULL,
	[PaymentType] [nvarchar](50) NOT NULL,
	[Name] [nvarchar](100) NULL,
	[MerchantCode] [nvarchar](4000) NOT NULL,
	[SecretKey] [nvarchar](4000) NULL,
	[SecondKey] [nvarchar](4000) NULL,
	[Pwd] [nvarchar](4000) NULL,
	[Partner] [nvarchar](100) NULL,
	[Email] [nvarchar](100) NULL,
	[Memo] [nvarchar](4000) NULL,
	[Charge] [decimal](18, 2) NOT NULL CONSTRAINT [DF_ShopNum1_Payment_Charge]  DEFAULT ((0)),
	[IsPercent] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Payment_IsPercent]  DEFAULT ((0)),
	[IsCOD] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Payment_IsCOD]  DEFAULT ((0)),
	[OrderID] [int] NOT NULL,
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Payment_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_Payment] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
/****** 对象:  Table [dbo].[ShopNum1_MemberGroup]    脚本日期: 10/02/2009 18:59:15 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_MemberGroup](
	[Guid] [uniqueidentifier] NOT NULL,
	[Name] [nvarchar](50) NOT NULL,
	[Description] [nvarchar](500) NULL,
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_MemberGroup_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_MemberGroup] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
/****** 对象:  Table [dbo].[ShopNum1_ScoreModifyLog]    脚本日期: 10/02/2009 19:02:45 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_ScoreModifyLog](
	[Guid] [uniqueidentifier] NOT NULL,
	[OperateType] [int] NOT NULL,
	[CurrentScore] [int] NOT NULL,
	[OperateScore] [int] NOT NULL,
	[LastOperateScore] [int] NOT NULL,
	[Date] [datetime] NOT NULL,
	[Memo] [nvarchar](250) NULL CONSTRAINT [DF_ShopNum1_ScoreModifyLog_Memo]  DEFAULT (NULL),
	[MemLoginID] [nvarchar](50) NOT NULL,
	[CreateUser] [nvarchar](50) NULL CONSTRAINT [DF_ShopNum1_ScoreModifyLog_CreateUser]  DEFAULT (NULL),
	[CreateTime] [datetime] NULL CONSTRAINT [DF_ShopNum1_ScoreModifyLog_CreateTime]  DEFAULT (NULL),
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_ScoreModifyLog_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_ScoreModifyLog] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
/****** 对象:  Table [dbo].[ShopNum1_UserDefinedColumn]    脚本日期: 10/02/2009 19:03:15 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_UserDefinedColumn](
	[Guid] [uniqueidentifier] NOT NULL,
	[Name] [nvarchar](50) NOT NULL,
	[LinkAddress] [nvarchar](150) NOT NULL,
	[ShowLocation] [nvarchar](20) NOT NULL,
	[IfShow] [int] NOT NULL CONSTRAINT [DF_ShopNum1_UserDefinedColumn_IfShow]  DEFAULT ((0)),
	[IfOpen] [int] NOT NULL CONSTRAINT [DF_ShopNum1_UserDefinedColumn_IfOpen]  DEFAULT ((0)),
	[Remark] [nvarchar](200) NULL,
	[OrderID] [int] NOT NULL CONSTRAINT [DF_ShopNum1_UserDefinedColumn_OrderID]  DEFAULT ((0)),
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_UserDefinedColumn_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_UserDefinedColumn] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
/****** 对象:  Table [dbo].[ShopNum1_Dept]    脚本日期: 10/02/2009 18:56:38 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_Dept](
	[Guid] [uniqueidentifier] NOT NULL,
	[Name] [nvarchar](50) NOT NULL,
	[ShortName] [nvarchar](20) NOT NULL,
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Dept_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_Num1_Dept] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'部门名称' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'ShopNum1_Dept', @level2type=N'COLUMN',@level2name=N'Name'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'部门缩写' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'ShopNum1_Dept', @level2type=N'COLUMN',@level2name=N'ShortName'
GO
/****** 对象:  Table [dbo].[ShopNum1_Link]    脚本日期: 10/02/2009 18:58:30 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_Link](
	[Guid] [uniqueidentifier] NOT NULL CONSTRAINT [DF_Table_1_GUID]  DEFAULT (newid()),
	[Name] [nvarchar](50) NULL,
	[ImgADD] [nvarchar](250) NULL,
	[Href] [nvarchar](250) NULL,
	[ImgType] [int] NULL CONSTRAINT [DF_ShopNum1_Link_ImgType]  DEFAULT ((0)),
	[OrderID] [int] NULL CONSTRAINT [DF_ShopNum1_Link_OrderID]  DEFAULT ((0)),
	[LinkType] [int] NULL CONSTRAINT [DF_ShopNum1_Link_LinkType]  DEFAULT ((0)),
	[Description] [nvarchar](250) NULL,
	[Memo] [nvarchar](150) NULL,
	[IsShow] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Link_IsShow]  DEFAULT ((0)),
	[CreateUser] [nvarchar](50) NULL,
	[CreateTime] [datetime] NULL,
	[ModifyUser] [nvarchar](50) NULL,
	[ModifyTime] [datetime] NULL,
	[IsDeleted] [int] NULL CONSTRAINT [DF_ShopNum1_Link_IsDeleted]  DEFAULT ((0))
) ON [PRIMARY]
GO
/****** 对象:  Table [dbo].[ShopNum1_MenuType]    脚本日期: 10/02/2009 18:59:33 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_MenuType](
	[GUID] [uniqueidentifier] NOT NULL,
	[TypeCode] [nvarchar](50) NULL,
	[TypeName] [nvarchar](50) NULL,
	[Description] [nvarchar](250) NULL,
	[State] [int] NULL,
	[CreateUser] [nvarchar](50) NULL,
	[CreateTime] [datetime] NULL,
	[ModifyUser] [nvarchar](50) NULL,
	[ModifyTime] [datetime] NULL,
	[IsDeleted] [int] NULL CONSTRAINT [DF_ShopNum1_MenuType_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_MenuType] PRIMARY KEY CLUSTERED 
(
	[GUID] 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
/****** 对象:  Table [dbo].[ShopNum1_ProductAttributeValue]    脚本日期: 10/02/2009 19:01:44 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_ProductAttributeValue](
	[Guid] [uniqueidentifier] NOT NULL,
	[ProductGuid] [uniqueidentifier] NOT NULL,
	[ProductTypeGuid] [uniqueidentifier] NULL,
	[ProductAttributeGuid] [uniqueidentifier] NOT NULL,
	[AtrributeValue] [ntext] NULL,
	[AttributePrice] [decimal](18, 2) NULL,
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_ProductAttributeValue_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_ProductAttributeValue] PRIMARY KEY CLUSTERED 
(
	[Guid] 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]
GO
/****** 对象:  Table [dbo].[ShopNum1_ScoreFreezeLog]    脚本日期: 10/02/2009 19:02:40 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_ScoreFreezeLog](
	[Guid] [uniqueidentifier] NOT NULL,
	[OperateType] [int] NOT NULL,
	[CurrentScore] [int] NOT NULL,
	[OperateScore] [int] NOT NULL,
	[LastOperateScore] [int] NOT NULL,
	[Date] [datetime] NOT NULL,
	[Memo] [nvarchar](250) NULL CONSTRAINT [DF_ShopNum1_ScoreFreezeLog_Memo]  DEFAULT (NULL),
	[MemLoginID] [nvarchar](50) NOT NULL,
	[CreateUser] [nvarchar](50) NULL CONSTRAINT [DF_ShopNum1_ScoreFreezeLog_CreateUser]  DEFAULT (NULL),
	[CreateTime] [datetime] NULL CONSTRAINT [DF_ShopNum1_ScoreFreezeLog_CreateTime]  DEFAULT (NULL),
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_ScoreFreezeLog_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_ScoreFreezeLog] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
/****** 对象:  Table [dbo].[ShopNum1_EmailGroupSend]    脚本日期: 10/02/2009 18:57:11 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_EmailGroupSend](
	[Guid] [uniqueidentifier] NOT NULL,
	[SendObject] [nvarchar](100) NOT NULL,
	[SendObjectEmail] [nvarchar](50) NOT NULL,
	[EmailTitle] [nvarchar](50) NOT NULL,
	[State] [int] NOT NULL CONSTRAINT [DF_ShopNum1_EmailGroupSend_State]  DEFAULT ((0)),
	[CreateTime] [datetime] NOT NULL,
	[IsTime] [int] NOT NULL CONSTRAINT [DF_ShopNum1_EmailGroupSend_IsTime]  DEFAULT ((0)),
	[TimeSendTime] [datetime] NULL,
	[EmailGuid] [uniqueidentifier] NOT NULL,
 CONSTRAINT [PK_ShopNum1_EmailGroupSend] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
/****** 对象:  Table [dbo].[ShopNum1_Article]    脚本日期: 10/02/2009 18:55:40 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_Article](
	[Guid] [uniqueidentifier] NOT NULL,
	[Title] [nvarchar](50) NOT NULL,
	[ArticleCategoryID] [int] NOT NULL,
	[Publisher] [nvarchar](50) NOT NULL,
	[Source] [nvarchar](150) NULL,
	[Content] [ntext] NOT NULL,
	[Keywords] [nvarchar](200) NULL,
	[Description] [nvarchar](150) NULL,
	[IsShow] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Article_IsShow]  DEFAULT ((1)),
	[IsAllowComment] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Article_IsAllowComment]  DEFAULT ((1)),
	[OrderID] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Article_OrderID]  DEFAULT ((0)),
	[IsHot] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Article_IsHot]  DEFAULT ((0)),
	[IsRecommend] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Article_IsRecommend]  DEFAULT ((0)),
	[IsHead] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Article_IsHead]  DEFAULT ((0)),
	[IsCanConfigure] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Article_IsCanConfigure]  DEFAULT ((0)),
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Article_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_Article] PRIMARY KEY CLUSTERED 
(
	[Guid] 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]
GO
/****** 对象:  Table [dbo].[ShopNum1_RankScoreModifyLog]    脚本日期: 10/02/2009 19:02:14 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_RankScoreModifyLog](
	[Guid] [uniqueidentifier] NOT NULL,
	[OperateType] [int] NOT NULL,
	[CurrentScore] [int] NOT NULL,
	[OperateScore] [int] NOT NULL,
	[LastOperateScore] [int] NOT NULL,
	[Date] [datetime] NOT NULL,
	[Memo] [nvarchar](250) NULL CONSTRAINT [DF_ShopNum1_RankScoreModifyLog_Memo]  DEFAULT (NULL),
	[MemLoginID] [nvarchar](50) NOT NULL,
	[CreateUser] [nvarchar](50) NULL CONSTRAINT [DF_ShopNum1_RankScoreModifyLog_CreateUser]  DEFAULT (NULL),
	[CreateTime] [datetime] NULL CONSTRAINT [DF_ShopNum1_RankScoreModifyLog_CreateTime]  DEFAULT (NULL),
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_RankScoreModifyLog_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_RankScoreModifyLog] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
/****** 对象:  Table [dbo].[ShopNum1_Currency]    脚本日期: 10/02/2009 18:56:34 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_Currency](
	[Guid] [uniqueidentifier] NOT NULL,
	[Type] [nvarchar](30) NOT NULL,
	[Name] [nvarchar](30) NOT NULL,
	[Symbol] [nvarchar](10) NOT NULL,
	[Rate] [money] NOT NULL,
	[IfDefault] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Currency_Manage_IfDefault]  DEFAULT ((0)),
	[OrderID] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Currency_Manage_OrderID]  DEFAULT ((0)),
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Currency_Manage_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_Currency] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
/****** 对象:  Table [dbo].[ShopNum1_OrderProduct]    脚本日期: 10/02/2009 19:00:24 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_OrderProduct](
	[Guid] [uniqueidentifier] NOT NULL,
	[OrderInfoGuid] [uniqueidentifier] NOT NULL,
	[ProductGuid] [uniqueidentifier] NOT NULL,
	[Name] [nvarchar](100) NOT NULL,
	[RepertoryNumber] [nvarchar](50) NOT NULL,
	[BuyNumber] [int] NOT NULL,
	[MarketPrice] [decimal](18, 2) NOT NULL,
	[ShopPrice] [decimal](18, 2) NOT NULL,
	[BuyPrice] [decimal](18, 2) NOT NULL,
	[Attributes] [nvarchar](250) NULL,
	[IsShipment] [int] NOT NULL CONSTRAINT [DF_ShopNum1_OrderProduct_IsShipment]  DEFAULT ((0)),
	[IsReal] [int] NOT NULL CONSTRAINT [DF_ShopNum1_OrderProduct_IsReal]  DEFAULT ((0)),
	[ExtensionAttriutes] [nvarchar](250) NULL,
	[ParentGuid] [uniqueidentifier] NULL,
	[IsJoinActivity] [int] NOT NULL CONSTRAINT [DF_ShopNum1_OrderProduct_IsJoinActivity]  DEFAULT ((0)),
	[IsPresent] [int] NOT NULL CONSTRAINT [DF_ShopNum1_OrderProduct_IsPresent]  DEFAULT ((0)),
	[CreateTime] [datetime] NOT NULL,
 CONSTRAINT [PK_ShopNum1_OrderProduct] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
/****** 对象:  Table [dbo].[ShopNum1_SalesPromotionInfo]    脚本日期: 10/02/2009 19:02:31 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_SalesPromotionInfo](
	[Guid] [uniqueidentifier] NOT NULL,
	[PromotionType] [nvarchar](50) NOT NULL,
	[Name] [nvarchar](50) NOT NULL,
	[OriginalImge] [nvarchar](250) NULL,
	[StartTime] [datetime] NOT NULL,
	[EndTime] [datetime] NOT NULL,
	[Description] [ntext] NOT NULL,
	[OrderID] [int] NOT NULL CONSTRAINT [DF_ShopNum1_SalesPromotionInfo_OrderID]  DEFAULT ((0)),
	[IsAllowFavourTicket] [int] NOT NULL CONSTRAINT [DF_ShopNum1_SalesPromotionInfo_IsAllowFavourTicket]  DEFAULT ((0)),
	[IsUsed] [int] NOT NULL CONSTRAINT [DF_ShopNum1_SalesPromotionInfo_IsUsed]  DEFAULT ((1)),
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_SalesPromotionInfo_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_SalesPromotionInfo] PRIMARY KEY CLUSTERED 
(
	[Guid] 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]
GO
/****** 对象:  Table [dbo].[ShopNum1_AuctionPrice]    脚本日期: 10/02/2009 18:56:04 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_AuctionPrice](
	[Guid] [uniqueidentifier] NOT NULL,
	[MemLoginID] [nvarchar](50) NOT NULL,
	[BidPrice] [decimal](18, 2) NOT NULL,
	[BidTime] [datetime] NOT NULL,
	[AuctionInfoGuid] [uniqueidentifier] NOT NULL,
 CONSTRAINT [PK_ShopNum1_AuctionPrice] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
/****** 对象:  Table [dbo].[ShopNum1_VirtualCard]    脚本日期: 10/02/2009 19:03:25 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_VirtualCard](
	[Guid] [uniqueidentifier] NOT NULL,
	[ProductGuid] [uniqueidentifier] NOT NULL,
	[CardNumber] [nvarchar](50) NOT NULL,
	[Pwd] [nvarchar](50) NOT NULL,
	[EndDate] [datetime] NOT NULL,
	[IsSaled] [int] NOT NULL CONSTRAINT [DF_ShopNum1_VirtualCard_IsSaled]  DEFAULT ((0)),
	[SaledDate] [datetime] NULL CONSTRAINT [DF_ShopNum1_VirtualCard_SaledDate]  DEFAULT (NULL),
	[OderNumber] [nvarchar](50) NULL CONSTRAINT [DF_ShopNum1_VirtualCard_OderNumber]  DEFAULT (NULL),
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_VirtualCard_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_VirtualCard] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
/****** 对象:  Table [dbo].[ShopNum1_LongAuctionInfo]    脚本日期: 10/02/2009 18:58:39 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_LongAuctionInfo](
	[Guid] [uniqueidentifier] NOT NULL,
	[ProductGuid] [uniqueidentifier] NOT NULL,
	[Name] [nvarchar](50) NOT NULL,
	[OriginalImge] [nvarchar](250) NULL CONSTRAINT [DF_ShopNum1_LongAuctionInfo_OriginalImge]  DEFAULT (NULL),
	[StartTime] [datetime] NOT NULL,
	[EndTime] [datetime] NOT NULL,
	[StartPrice] [decimal](18, 2) NOT NULL CONSTRAINT [DF_ShopNum1_LongAuctionInfo_LowerPrice]  DEFAULT ((0)),
	[OnePrice] [decimal](18, 2) NOT NULL CONSTRAINT [DF_ShopNum1_LongAuctionInfo_UpperPrice]  DEFAULT ((0)),
	[ExtentPrice] [decimal](18, 2) NOT NULL CONSTRAINT [DF_ShopNum1_LongAuctionInfo_MostPrice]  DEFAULT ((0)),
	[Deposit] [int] NOT NULL CONSTRAINT [DF_ShopNum1_LongAuctionInfo_Cconsume]  DEFAULT ((0)),
	[Memo] [ntext] NOT NULL,
	[IsEnd] [int] NOT NULL CONSTRAINT [DF_ShopNum1_LongAuctionInfo_IsEnd]  DEFAULT ((0)),
	[OrderID] [int] NOT NULL CONSTRAINT [DF_ShopNum1_LongAuctionInfo_OrderID]  DEFAULT ((0)),
	[MemLoginID] [nvarchar](50) NULL CONSTRAINT [DF_ShopNum1_LongAuctionInfo_MemLoginID]  DEFAULT (NULL),
	[BidPrice] [decimal](18, 2) NULL CONSTRAINT [DF_ShopNum1_LongAuctionInfo_BidPrice]  DEFAULT ((0)),
	[BidTime] [datetime] NULL CONSTRAINT [DF_ShopNum1_LongAuctionInfo_BidTime]  DEFAULT (NULL),
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_LongAuctionInfo_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_LongAuctionInfo] PRIMARY KEY CLUSTERED 
(
	[Guid] 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]
GO
/****** 对象:  Table [dbo].[ShopNum1_OrderInfo]    脚本日期: 10/02/2009 19:00:13 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_OrderInfo](
	[Guid] [uniqueidentifier] NOT NULL,
	[MemLoginID] [nvarchar](50) NULL,
	[OrderNumber] [nvarchar](50) NOT NULL,
	[OderStatus] [int] NOT NULL CONSTRAINT [DF_ShopNum1_OrderInfo_OderStatus]  DEFAULT ((0)),
	[ShipmentStatus] [int] NOT NULL CONSTRAINT [DF_ShopNum1_OrderInfo_ShipmentStatus]  DEFAULT ((0)),
	[PaymentStatus] [int] NOT NULL CONSTRAINT [DF_ShopNum1_OrderInfo_PaymentStatus]  DEFAULT ((0)),
	[Name] [nvarchar](50) NOT NULL,
	[Email] [nvarchar](100) NOT NULL,
	[Address] [nvarchar](250) NULL,
	[Postalcode] [nvarchar](20) NULL,
	[Tel] [nvarchar](20) NULL,
	[Mobile] [nvarchar](20) NULL,
	[ClientToSellerMsg] [nvarchar](1000) NULL,
	[SellerToClientMsg] [nvarchar](1000) NULL,
	[DispatchModeGuid] [uniqueidentifier] NOT NULL,
	[DispatchModeName] [nvarchar](50) NOT NULL,
	[PaymentGuid] [uniqueidentifier] NOT NULL,
	[PaymentName] [nvarchar](50) NOT NULL,
	[OutOfStockOperate] [nvarchar](50) NULL,
	[PackGuid] [uniqueidentifier] NULL,
	[PackName] [nvarchar](50) NULL,
	[BlessCardGuid] [uniqueidentifier] NULL,
	[BlessCardName] [nvarchar](50) NULL,
	[BlessCardContent] [nvarchar](4000) NULL,
	[InvoiceTitle] [nvarchar](50) NULL,
	[InvoiceContent] [nvarchar](50) NULL,
	[ProductPrice] [decimal](18, 2) NOT NULL,
	[DispatchPrice] [decimal](18, 2) NOT NULL,
	[InsurePrice] [decimal](18, 2) NOT NULL CONSTRAINT [DF_ShopNum1_OrderInfo_InsurePrice]  DEFAULT ((0)),
	[PaymentPrice] [decimal](18, 2) NOT NULL CONSTRAINT [DF_ShopNum1_OrderInfo_PaymentPrice]  DEFAULT ((0)),
	[PackPrice] [decimal](18, 2) NOT NULL CONSTRAINT [DF_ShopNum1_OrderInfo_PackPrice]  DEFAULT ((0)),
	[BlessCardPrice] [decimal](18, 2) NOT NULL CONSTRAINT [DF_ShopNum1_OrderInfo_BlessCardPrice]  DEFAULT ((0)),
	[AlreadPayPrice] [decimal](18, 2) NOT NULL,
	[SurplusPrice] [decimal](18, 2) NOT NULL CONSTRAINT [DF_ShopNum1_OrderInfo_SurplusPrice]  DEFAULT ((0)),
	[UseScore] [int] NOT NULL CONSTRAINT [DF_ShopNum1_OrderInfo_UseScore]  DEFAULT ((0)),
	[ScorePrice] [decimal](18, 2) NOT NULL CONSTRAINT [DF_ShopNum1_OrderInfo_ScorePrice]  DEFAULT ((0)),
	[ShouldPayPrice] [decimal](18, 2) NOT NULL,
	[FromAd] [uniqueidentifier] NULL,
	[FromUrl] [nvarchar](250) NULL,
	[CreateTime] [datetime] NOT NULL,
	[ConfirmTime] [datetime] NULL,
	[PayTime] [datetime] NULL CONSTRAINT [DF_ShopNum1_OrderInfo_PayTime]  DEFAULT (NULL),
	[DispatchTime] [datetime] NULL CONSTRAINT [DF_ShopNum1_OrderInfo_DispatchTime]  DEFAULT (NULL),
	[ShipmentNumber] [nvarchar](50) NULL CONSTRAINT [DF_ShopNum1_OrderInfo_ShipmentNumber]  DEFAULT (NULL),
	[BuyType] [nvarchar](50) NULL CONSTRAINT [DF_ShopNum1_OrderInfo_BuyType]  DEFAULT (N'n'),
	[ActivityGuid] [uniqueidentifier] NULL,
	[PayMemo] [nvarchar](500) NULL,
	[InvoiceType] [nvarchar](50) NULL,
	[InvoiceTax] [decimal](18, 2) NOT NULL CONSTRAINT [DF_ShopNum1_OrderInfo_InvoiceTax]  DEFAULT ((0)),
	[Discount] [decimal](18, 2) NOT NULL CONSTRAINT [DF_ShopNum1_OrderInfo_Discount]  DEFAULT ((0)),
	[Deposit] [decimal](18, 2) NULL CONSTRAINT [DF_ShopNum1_OrderInfo_eposit]  DEFAULT ((0)),
	[IsPayDeposit] [int] NULL CONSTRAINT [DF_ShopNum1_OrderInfo_IsPayDeposit]  DEFAULT ((0)),
	[CreateUser] [nvarchar](50) NULL,
	[ModifyUser] [nvarchar](50) NULL,
	[ModifyTime] [datetime] NULL CONSTRAINT [DF_ShopNum1_OrderInfo_ModifyTime]  DEFAULT (NULL),
	[IsDeleted] [int] NULL CONSTRAINT [DF_ShopNum1_OrderInfo_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_OrderInfo] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
/****** 对象:  Table [dbo].[ShopNum1_ArticleComment]    脚本日期: 10/02/2009 18:55:52 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_ArticleComment](
	[Guid] [uniqueidentifier] NOT NULL,
	[ArticleGuid] [uniqueidentifier] NOT NULL,
	[MemLoginID] [nvarchar](50) NULL,
	[Title] [nvarchar](200) NULL,
	[Rank] [int] NOT NULL,
	[SendTime] [datetime] NOT NULL,
	[Content] [ntext] NULL,
	[IPAddress] [nvarchar](50) NOT NULL,
	[ReplyUser] [nvarchar](50) NULL,
	[ReplyTime] [datetime] NULL,
	[ReplyContent] [ntext] NULL,
	[IsAudit] [int] NOT NULL CONSTRAINT [DF_ShopNum1_ArticleComment_IsAudit]  DEFAULT ((0)),
	[IsReply] [int] NOT NULL CONSTRAINT [DF_ShopNum1_ArticleComment_IsReply]  DEFAULT ((0)),
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_ArticleComment_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_ArticleComment] PRIMARY KEY CLUSTERED 
(
	[Guid] 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]
GO
/****** 对象:  Table [dbo].[ShopNum1_Cart]    脚本日期: 10/02/2009 18:56:26 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_Cart](
	[Guid] [uniqueidentifier] NOT NULL,
	[MemLoginID] [nvarchar](50) NULL,
	[ProductGuid] [uniqueidentifier] NOT NULL,
	[OriginalImge] [nvarchar](250) NULL,
	[Name] [nvarchar](100) NOT NULL,
	[RepertoryNumber] [nvarchar](50) NOT NULL,
	[BuyNumber] [int] NOT NULL,
	[MarketPrice] [decimal](18, 2) NOT NULL,
	[ShopPrice] [decimal](18, 2) NOT NULL,
	[BuyPrice] [decimal](18, 2) NOT NULL,
	[Attributes] [nvarchar](250) NULL,
	[IsShipment] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Cart_IsShipment]  DEFAULT ((0)),
	[IsReal] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Cart_IsReal]  DEFAULT ((0)),
	[ExtensionAttriutes] [nvarchar](250) NULL,
	[ParentGuid] [uniqueidentifier] NULL,
	[IsJoinActivity] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Cart_IsJoinActivity]  DEFAULT ((0)),
	[CartType] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Cart_CartType]  DEFAULT ((0)),
	[IsPresent] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Cart_IsPresent]  DEFAULT ((0)),
	[CreateTime] [datetime] NOT NULL,
 CONSTRAINT [PK_ShopNum1_Cart] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
/****** 对象:  Table [dbo].[ShopNum1_AuctionInfo]    脚本日期: 10/02/2009 18:56:02 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_AuctionInfo](
	[Guid] [uniqueidentifier] NOT NULL,
	[ProductGuid] [uniqueidentifier] NOT NULL,
	[Name] [nvarchar](50) NOT NULL,
	[OriginalImge] [nvarchar](250) NULL CONSTRAINT [DF_ShopNum1_AuctionInfo_OriginalImge]  DEFAULT (NULL),
	[StartTime] [datetime] NOT NULL,
	[EndTime] [datetime] NOT NULL,
	[LowerPrice] [decimal](18, 2) NOT NULL CONSTRAINT [DF_ShopNum1_AuctionInfo_LowerPrice]  DEFAULT ((0)),
	[UpperPrice] [decimal](18, 2) NOT NULL CONSTRAINT [DF_ShopNum1_AuctionInfo_UpperPrice]  DEFAULT ((0)),
	[MostPrice] [decimal](18, 2) NOT NULL CONSTRAINT [DF_ShopNum1_AuctionInfo_MostPrice]  DEFAULT ((0)),
	[ConsumeScore] [int] NOT NULL CONSTRAINT [DF_ShopNum1_AuctionInfo_Cconsume]  DEFAULT ((0)),
	[Memo] [ntext] NULL,
	[IsEnd] [int] NOT NULL CONSTRAINT [DF_ShopNum1_AuctionInfo_IsEnd]  DEFAULT ((0)),
	[OrderID] [int] NOT NULL CONSTRAINT [DF_ShopNum1_AuctionInfo_OrderID]  DEFAULT ((0)),
	[MemLoginID] [nvarchar](50) NULL CONSTRAINT [DF_ShopNum1_AuctionInfo_MemLoginID]  DEFAULT (NULL),
	[BidPrice] [decimal](18, 2) NULL CONSTRAINT [DF_ShopNum1_AuctionInfo_BidPrice]  DEFAULT ((0)),
	[BidTime] [datetime] NULL CONSTRAINT [DF_ShopNum1_AuctionInfo_BidTime]  DEFAULT (NULL),
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_AuctionInfo_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_AuctionInfo] PRIMARY KEY CLUSTERED 
(
	[Guid] 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]
GO
/****** 对象:  Table [dbo].[ShopNum1_Menu]    脚本日期: 10/02/2009 18:59:29 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_Menu](
	[Guid] [uniqueidentifier] NOT NULL,
	[Name] [nvarchar](20) NOT NULL,
	[Code] [nvarchar](50) NOT NULL,
	[OrderID] [int] NOT NULL,
	[TypeCode] [nvarchar](50) NOT NULL,
	[State] [int] NOT NULL,
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Menu_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_Menu] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
/****** 对象:  Table [dbo].[ShopNum1_Group]    脚本日期: 10/02/2009 18:57:35 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_Group](
	[Guid] [uniqueidentifier] NOT NULL CONSTRAINT [DF_ShopNum1_Group_Guid]  DEFAULT (newid()),
	[Name] [nvarchar](50) NOT NULL,
	[ShortName] [nvarchar](20) NOT NULL,
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Group_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_Group] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
/****** 对象:  Table [dbo].[ShopNum1_Announcement]    脚本日期: 10/02/2009 18:55:31 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_Announcement](
	[Guid] [uniqueidentifier] NOT NULL,
	[Title] [nvarchar](50) NOT NULL,
	[Remark] [text] NOT NULL,
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Announcement_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_Announcement] PRIMARY KEY CLUSTERED 
(
	[Guid] 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]
GO
/****** 对象:  Table [dbo].[ShopNum1_ProdcutExtendType]    脚本日期: 10/02/2009 19:01:07 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_ProdcutExtendType](
	[ProductGuid] [uniqueidentifier] NOT NULL,
	[ProductCategoryID] [int] NOT NULL,
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL
) ON [PRIMARY]
GO
/****** 对象:  Table [dbo].[ShopNum1_LongAuctionPrice]    脚本日期: 10/02/2009 18:58:42 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_LongAuctionPrice](
	[Guid] [uniqueidentifier] NOT NULL,
	[MemLoginID] [nvarchar](50) NOT NULL,
	[BidPrice] [decimal](18, 2) NOT NULL,
	[BidTime] [datetime] NOT NULL,
	[LongAuctionInfoGuid] [uniqueidentifier] NOT NULL,
	[IsFirst] [int] NOT NULL CONSTRAINT [DF_ShopNum1_LongAuctionPrice_IsFirst]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_LongAuctionPrice] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
/****** 对象:  Table [dbo].[ShopNum1_GroupPage]    脚本日期: 10/02/2009 18:57:38 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_GroupPage](
	[GroupGuid] [uniqueidentifier] NOT NULL,
	[PageGuid] [nvarchar](50) NOT NULL,
	[CreateUser] [nchar](10) NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_GroupPage_IsDeleted]  DEFAULT ((0))
) ON [PRIMARY]
GO
/****** 对象:  Table [dbo].[ShopNum1_LetterOfAdvice]    脚本日期: 10/02/2009 18:58:23 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_LetterOfAdvice](
	[Guid] [uniqueidentifier] NOT NULL,
	[OrderGuid] [nvarchar](100) NOT NULL,
	[MemLoginID] [nvarchar](50) NOT NULL,
	[Name] [nvarchar](50) NOT NULL,
	[Fashion] [nvarchar](50) NOT NULL,
	[SendNumber] [nvarchar](50) NOT NULL,
	[SendTime] [datetime] NOT NULL,
	[Memo] [nvarchar](250) NOT NULL,
	[IsShow] [int] NOT NULL CONSTRAINT [DF_ShopNum1_LetterOfAdvice_IsShow]  DEFAULT ((1)),
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_LetterOfAdvice_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_LetterOfAdvice] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
/****** 对象:  Table [dbo].[ShopNum1_BlessCard]    脚本日期: 10/02/2009 18:56:09 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_BlessCard](
	[Guid] [uniqueidentifier] NOT NULL,
	[Name] [nvarchar](50) NOT NULL,
	[Cost] [decimal](18, 2) NOT NULL,
	[FreeLimit] [decimal](18, 2) NOT NULL,
	[CardImagePath] [nvarchar](250) NOT NULL,
	[Description] [nvarchar](150) NULL,
	[OrderID] [int] NOT NULL,
	[IfUse] [int] NOT NULL CONSTRAINT [DF_ShopNum1_BlessCard_IfUse]  DEFAULT ((0)),
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_BlessCard_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_BlessCard] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
/****** 对象:  Table [dbo].[ShopNum1_ProductArticle]    脚本日期: 10/02/2009 19:01:33 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_ProductArticle](
	[ProductGuid] [uniqueidentifier] NOT NULL,
	[ArticleGuid] [uniqueidentifier] NOT NULL,
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL
) ON [PRIMARY]
GO
/****** 对象:  Table [dbo].[ShopNum1_ProductImage]    脚本日期: 10/02/2009 19:02:01 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_ProductImage](
	[Guid] [uniqueidentifier] NOT NULL,
	[ProductGuid] [uniqueidentifier] NOT NULL,
	[OriginalImge] [nvarchar](250) NOT NULL,
	[ThumbImage] [nvarchar](250) NULL,
	[SmallImage] [nvarchar](250) NULL,
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_PorductImage_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_PorductImage] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
/****** 对象:  Table [dbo].[ShopNum1_EmailBook]    脚本日期: 10/02/2009 18:57:04 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_EmailBook](
	[Guid] [uniqueidentifier] NOT NULL,
	[BookTypeName] [nvarchar](50) NOT NULL,
	[EmailAddress] [nvarchar](50) NULL,
	[State] [int] NOT NULL CONSTRAINT [DF_ShopNum1_EmailBook_State]  DEFAULT ((0)),
	[CreateUser] [nvarchar](50) NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_EmailBook_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_EmailBook] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
/****** 对象:  Table [dbo].[ShopNum1_PageWebControl]    脚本日期: 10/02/2009 19:00:58 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_PageWebControl](
	[Guid] [uniqueidentifier] NOT NULL CONSTRAINT [DF_ShopNum1_PageWebControl_Guid]  DEFAULT (newid()),
	[Name] [nvarchar](50) NOT NULL,
	[PageGuid] [uniqueidentifier] NOT NULL,
	[ControlID] [nvarchar](50) NOT NULL,
	[ControlType] [nvarchar](50) NOT NULL,
	[Description] [nvarchar](100) NULL,
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_PageWebControl_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_PageWebControl] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
/****** 对象:  Table [dbo].[ShopNum1_EmailBookType]    脚本日期: 10/02/2009 18:57:08 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_EmailBookType](
	[Guid] [uniqueidentifier] NOT NULL,
	[BookTypeName] [nvarchar](50) NOT NULL,
	[Description] [nvarchar](200) NULL,
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_EmailBookType_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_EmailBookType] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
/****** 对象:  Table [dbo].[ShopNum1_RelatedProduct]    脚本日期: 10/02/2009 19:02:23 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_RelatedProduct](
	[ProductGuid] [uniqueidentifier] NOT NULL,
	[IsBoth] [int] NOT NULL CONSTRAINT [DF_ShopNum1_RelatedProduct_IsBoth]  DEFAULT ((0)),
	[SubProductGuid] [uniqueidentifier] NOT NULL,
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL
) ON [PRIMARY]
GO
/****** 对象:  Table [dbo].[ShopNum1_GroupUser]    脚本日期: 10/02/2009 18:57:46 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_GroupUser](
	[GroupGuid] [uniqueidentifier] NOT NULL,
	[UserGuid] [uniqueidentifier] NOT NULL,
	[CreateUser] [nvarchar](50) NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_GroupUser_IsDeleted]  DEFAULT ((0))
) ON [PRIMARY]
GO
/****** 对象:  Table [dbo].[ShopNum1_EmailType]    脚本日期: 10/02/2009 18:57:15 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_EmailType](
	[Guid] [uniqueidentifier] NOT NULL,
	[TypeName] [nvarchar](50) NOT NULL,
	[Description] [nvarchar](200) NULL,
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_EmailType_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_EmailType] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
/****** 对象:  Table [dbo].[ShopNum1_GroupPageWebControl]    脚本日期: 10/02/2009 18:57:44 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_GroupPageWebControl](
	[Guid] [uniqueidentifier] NOT NULL CONSTRAINT [DF_ShopNum1_GroupPageWebControl_Guid]  DEFAULT (newid()),
	[PageWebControlGuid] [uniqueidentifier] NOT NULL,
	[GroupGuid] [uniqueidentifier] NOT NULL,
	[IsUse] [int] NOT NULL,
	[IsShow] [int] NOT NULL,
	[PageGuid] [uniqueidentifier] NOT NULL,
	[ControlID] [nvarchar](50) NOT NULL,
	[ControlType] [nvarchar](50) NOT NULL,
	[CreateUser] [nvarchar](50) NOT NULL CONSTRAINT [DF_ShopNum1_GroupPageWebControl_CreateUser]  DEFAULT ((50)),
	[CreateTime] [datetime] NOT NULL CONSTRAINT [DF_ShopNum1_GroupPageWebControl_CreateTime]  DEFAULT ((8)),
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL CONSTRAINT [DF_ShopNum1_GroupPageWebControl_ModifyTime]  DEFAULT ((8)),
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_GroupPageWebControl_IsDeleted]  DEFAULT ((4))
) ON [PRIMARY]
GO
/****** 对象:  Table [dbo].[ShopNum1_ProductAccessory]    脚本日期: 10/02/2009 19:01:31 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_ProductAccessory](
	[ProductGuid] [uniqueidentifier] NOT NULL,
	[AccessoryProductGuid] [uniqueidentifier] NOT NULL,
	[Price] [decimal](18, 2) NOT NULL CONSTRAINT [DF_ShopNum1_ProductAccessory_Price]  DEFAULT ((0)),
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL
) ON [PRIMARY]
GO
/****** 对象:  Table [dbo].[ShopNum1_Member]    脚本日期: 10/02/2009 18:59:03 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_Member](
	[Guid] [uniqueidentifier] NOT NULL,
	[MemLoginID] [nvarchar](50) NOT NULL,
	[Email] [nvarchar](100) NOT NULL,
	[Pwd] [nvarchar](50) NOT NULL,
	[PayPwd] [nvarchar](50) NULL,
	[Sex] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Member_Sex]  DEFAULT ((0)),
	[Age] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Member_Age]  DEFAULT ((0)),
	[Birthday] [datetime] NULL CONSTRAINT [DF_ShopNum1_Member_Birthday]  DEFAULT (NULL),
	[CreditMoney] [decimal](18, 2) NOT NULL CONSTRAINT [DF_ShopNum1_Member_CreditMoney]  DEFAULT ((0)),
	[Photo] [nvarchar](250) NULL CONSTRAINT [DF_ShopNum1_Member_Photo]  DEFAULT (NULL),
	[RealName] [nvarchar](50) NULL CONSTRAINT [DF_ShopNum1_Member_RealName]  DEFAULT (NULL),
	[Area] [nvarchar](50) NULL CONSTRAINT [DF_ShopNum1_Member_Area]  DEFAULT (NULL),
	[Vocation] [nvarchar](100) NULL CONSTRAINT [DF_ShopNum1_Member_Vocation]  DEFAULT (NULL),
	[Address] [nvarchar](250) NULL CONSTRAINT [DF_ShopNum1_Member_Address]  DEFAULT (NULL),
	[Postalcode] [nvarchar](20) NULL CONSTRAINT [DF_ShopNum1_Member_Postalcode]  DEFAULT (NULL),
	[OfficeTel] [nvarchar](20) NULL CONSTRAINT [DF_ShopNum1_Member_OfficeTel]  DEFAULT (NULL),
	[HomeTel] [nvarchar](20) NULL CONSTRAINT [DF_ShopNum1_Member_HomeTel]  DEFAULT (NULL),
	[Mobile] [nvarchar](20) NULL CONSTRAINT [DF_ShopNum1_Member_Mobile]  DEFAULT (NULL),
	[Fax] [nvarchar](20) NULL CONSTRAINT [DF_ShopNum1_Member_Fax]  DEFAULT (NULL),
	[QQ] [nvarchar](15) NULL CONSTRAINT [DF_ShopNum1_Member_QQ]  DEFAULT (NULL),
	[Msn] [nvarchar](50) NULL CONSTRAINT [DF_ShopNum1_Member_Msn]  DEFAULT (NULL),
	[CardType] [nvarchar](20) NULL CONSTRAINT [DF_ShopNum1_Member_CardType]  DEFAULT (NULL),
	[CardNum] [nvarchar](50) NULL CONSTRAINT [DF_ShopNum1_Member_CardNum]  DEFAULT (NULL),
	[WebSite] [nvarchar](250) NULL CONSTRAINT [DF_ShopNum1_Member_WebSite]  DEFAULT (NULL),
	[Question] [nvarchar](50) NULL CONSTRAINT [DF_ShopNum1_Member_Question]  DEFAULT (NULL),
	[Answer] [nvarchar](50) NULL CONSTRAINT [DF_ShopNum1_Member_Answer]  DEFAULT (NULL),
	[RegDate] [datetime] NULL CONSTRAINT [DF_ShopNum1_Member_RegDate]  DEFAULT (NULL),
	[LastLoginDate] [datetime] NULL CONSTRAINT [DF_ShopNum1_Member_LastLoginDate]  DEFAULT (NULL),
	[LastLoginIP] [nvarchar](25) NULL CONSTRAINT [DF_ShopNum1_Member_LastLoginIP]  DEFAULT (NULL),
	[LoginTime] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Member_LoginTime]  DEFAULT ((0)),
	[AdvancePayment] [decimal](18, 2) NOT NULL CONSTRAINT [DF_ShopNum1_Member_AdvancePayment]  DEFAULT ((0)),
	[Score] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Member_Score]  DEFAULT ((0)),
	[RankScore] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Member_RankScore]  DEFAULT ((0)),
	[LockAdvancePayment] [decimal](18, 2) NOT NULL CONSTRAINT [DF_ShopNum1_Member_LockAdvancePayment]  DEFAULT ((0)),
	[LockSocre] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Member_LockSocre]  DEFAULT ((0)),
	[CostMoney] [decimal](18, 2) NOT NULL CONSTRAINT [DF_ShopNum1_Member_CostMoney]  DEFAULT ((0)),
	[MemberRankGuid] [uniqueidentifier] NULL,
	[TradeCount] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Member_TradeCount]  DEFAULT ((0)),
	[IsForbid] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Member_IsForbid]  DEFAULT ((0)),
	[CreateUser] [nvarchar](50) NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Member_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_Member] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
/****** 对象:  Table [dbo].[ShopNum1_Email]    脚本日期: 10/02/2009 18:57:00 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_Email](
	[Guid] [uniqueidentifier] NOT NULL,
	[TypeName] [nvarchar](50) NOT NULL,
	[Title] [nvarchar](50) NOT NULL,
	[Remark] [ntext] NOT NULL,
	[Description] [nvarchar](100) NULL,
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Email_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_Email] PRIMARY KEY CLUSTERED 
(
	[Guid] 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]
GO
/****** 对象:  Table [dbo].[ShopNum1_ArticleCategory]    脚本日期: 10/02/2009 18:55:46 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
IF NOT EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[ShopNum1_ArticleCategory]') AND type in (N'U'))
BEGIN
CREATE TABLE [dbo].[ShopNum1_ArticleCategory](
	[ID] [int] NOT NULL,
	[Name] [nvarchar](50) NOT NULL,
	[Keywords] [nvarchar](200) NOT NULL,
	[Description] [nvarchar](150) NOT NULL,
	[OrderID] [int] NOT NULL CONSTRAINT [DF_ShopNum1_ArticleCategory_OrderID]  DEFAULT ((0)),
	[IsShow] [int] NOT NULL CONSTRAINT [DF_ShopNum1_ArticleCategory_IsShow]  DEFAULT ((1)),
	[CategoryLevel] [int] NOT NULL CONSTRAINT [DF_ShopNum1_ArticleCategory_CategoryLevel]  DEFAULT ((0)),
	[FatherID] [int] NOT NULL,
	[Family] [nvarchar](250) NULL,
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_ArticleCategory_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_ArticleCategory] PRIMARY KEY CLUSTERED 
(
	[ID] ASC
)WITH (IGNORE_DUP_KEY = OFF) ON [PRIMARY]
) ON [PRIMARY]
END
GO
/****** 对象:  Table [dbo].[ShopNum1_OnlineService]    脚本日期: 10/02/2009 18:59:47 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_OnlineService](
	[Guid] [uniqueidentifier] NOT NULL,
	[Type] [nvarchar](50) NOT NULL,
	[Name] [nvarchar](50) NOT NULL,
	[ServiceAccount] [nvarchar](100) NOT NULL,
	[Location] [nvarchar](20) NOT NULL,
	[IfShow] [int] NOT NULL CONSTRAINT [DF_ShopNum1_ OnlineService_IfShow]  DEFAULT ((0)),
	[OrderID] [int] NOT NULL CONSTRAINT [DF_ShopNum1_ OnlineService_OrderID]  DEFAULT ((0)),
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_ OnlineService_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_OnlineService] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
/****** 对象:  Table [dbo].[ShopNum1_OrganizBuyPrice]    脚本日期: 10/02/2009 19:00:36 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_OrganizBuyPrice](
	[Guid] [uniqueidentifier] NOT NULL,
	[Amount] [int] NOT NULL CONSTRAINT [DF_ShopNum1_OrganizBuyPrice_Amount]  DEFAULT ((0)),
	[Price] [decimal](18, 2) NOT NULL,
	[OrganizBuyInfoGuid] [uniqueidentifier] NOT NULL,
 CONSTRAINT [PK_ShopNum1_OrganizBuyPrice] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
/****** 对象:  Table [dbo].[ShopNum1_User]    脚本日期: 10/02/2009 19:03:09 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_User](
	[Guid] [uniqueidentifier] NOT NULL,
	[LoginId] [nvarchar](50) NOT NULL,
	[Pwd] [nvarchar](50) NOT NULL,
	[RealName] [nvarchar](50) NOT NULL,
	[Sex] [int] NOT NULL,
	[Age] [int] NOT NULL CONSTRAINT [DF_ShopNum1_User_Age]  DEFAULT ((0)),
	[WorkNumber] [nvarchar](50) NOT NULL CONSTRAINT [DF_ShopNum1_User_WorkNumber]  DEFAULT ((0)),
	[Email] [nvarchar](100) NULL,
	[Telephone] [nvarchar](100) NULL,
	[IsForbid] [int] NOT NULL CONSTRAINT [DF_ShopNum1_User_IsForbid]  DEFAULT ((0)),
	[LoginTimes] [int] NOT NULL CONSTRAINT [DF_ShopNum1_User_LoginTimes]  DEFAULT ((0)),
	[LastLoginTime] [datetime] NULL,
	[LastLoginIP] [nvarchar](20) NULL,
	[LastModifyPasswordTime] [datetime] NULL,
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_User_IsDeleted]  DEFAULT ((0)),
	[DeptGuid] [uniqueidentifier] NULL,
 CONSTRAINT [PK_ShopNum1_User] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
/****** 对象:  Table [dbo].[ShopNum1_FavourTicket]    脚本日期: 10/02/2009 18:57:20 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_FavourTicket](
	[Guid] [uniqueidentifier] NOT NULL,
	[Name] [nvarchar](50) NOT NULL,
	[MinimalCost] [decimal](18, 2) NOT NULL,
	[StartDate] [datetime] NOT NULL,
	[EndDate] [datetime] NOT NULL,
	[FaceValue] [decimal](18, 2) NOT NULL,
	[LimitTimes] [int] NOT NULL CONSTRAINT [DF_ShopNum1_FavourTicket_LimitTimes]  DEFAULT ((0)),
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_FavourTicket_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_FavourTicket] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
/****** 对象:  Table [dbo].[ShopNum1_RelatedArticle]    脚本日期: 10/02/2009 19:02:21 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_RelatedArticle](
	[ArticleGuid] [uniqueidentifier] NOT NULL,
	[IsBoth] [int] NOT NULL CONSTRAINT [DF_ShopNum1_RelatedArticle_IsBoth]  DEFAULT ((0)),
	[SubArticleGuid] [uniqueidentifier] NOT NULL,
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
 CONSTRAINT [PK_ShopNum1_RelatedArticle] PRIMARY KEY CLUSTERED 
(
	[ArticleGuid] ASC,
	[SubArticleGuid] 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
/****** 对象:  Table [dbo].[ShopNum1_Image]    脚本日期: 10/02/2009 18:58:06 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_Image](
	[Guid] [uniqueidentifier] NOT NULL,
	[Name] [nvarchar](50) NOT NULL,
	[ImageType] [uniqueidentifier] NOT NULL,
	[ImagePath] [nvarchar](250) NOT NULL,
	[Description] [nvarchar](100) NULL,
	[UseTimes] [int] NOT NULL,
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNUM1_Image_IsDelete]  DEFAULT ((0)),
	[IsDownLoad] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Image_IsDownLoad]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNUM1_Image] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
/****** 对象:  Table [dbo].[ShopNum1_WholesaleInfo]    脚本日期: 10/02/2009 19:03:30 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_WholesaleInfo](
	[Guid] [uniqueidentifier] NOT NULL,
	[ProductGuid] [uniqueidentifier] NOT NULL,
	[OriginalImge] [nvarchar](250) NULL CONSTRAINT [DF_ShopNum1_WholesaleInfo_OriginalImge]  DEFAULT (NULL),
	[RankGuids] [nvarchar](4000) NULL CONSTRAINT [DF_ShopNum1_WholesaleInfo_RankGuids]  DEFAULT (NULL),
	[IsUse] [int] NOT NULL CONSTRAINT [DF_ShopNum1_WholesaleInfo_IsUse]  DEFAULT ((1)),
	[Memo] [ntext] NOT NULL,
	[OrderID] [int] NOT NULL CONSTRAINT [DF_ShopNum1_WholesaleInfo_OrderID]  DEFAULT ((0)),
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_WholesaleInfo_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_WholesaleInfo] PRIMARY KEY CLUSTERED 
(
	[Guid] 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]
GO
/****** 对象:  Table [dbo].[ShopNum1_MemberFavourTicket]    脚本日期: 10/02/2009 18:59:11 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_MemberFavourTicket](
	[FavourTicketCode] [nvarchar](50) NOT NULL,
	[Guid] [uniqueidentifier] NOT NULL,
	[Name] [nvarchar](50) NOT NULL,
	[MinimalCost] [decimal](18, 2) NOT NULL,
	[StartDate] [datetime] NOT NULL,
	[EndDate] [datetime] NOT NULL,
	[FaceValue] [decimal](18, 2) NOT NULL,
	[LimitTimes] [int] NOT NULL CONSTRAINT [DF_ShopNum1_MemberFavourTicket_LimitTimes]  DEFAULT ((0)),
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_MemberFavourTicket_IsDeleted]  DEFAULT ((0)),
	[MemLoginID] [nvarchar](50) NOT NULL,
 CONSTRAINT [PK_ShopNum1_MemberFavourTicket_1] PRIMARY KEY CLUSTERED 
(
	[FavourTicketCode] 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
/****** 对象:  Table [dbo].[ShopNum1_Image_Type]    脚本日期: 10/02/2009 18:58:10 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_Image_Type](
	[Guid] [uniqueidentifier] NOT NULL,
	[Name] [nvarchar](50) NOT NULL,
	[Description] [nvarchar](50) NULL,
	[IfSpecial] [int] NOT NULL CONSTRAINT [DF_ShopNum1_IMAGE_TYPE_IfSpecial]  DEFAULT ((0)),
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_IMAGE_TYPE_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_Image_Type] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
/****** 对象:  Table [dbo].[ShopNum1_OperateLog]    脚本日期: 10/02/2009 18:59:50 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_OperateLog](
	[Guid] [uniqueidentifier] NOT NULL,
	[Record] [nvarchar](250) NULL,
	[OperatorID] [nvarchar](50) NULL,
	[IP] [nvarchar](50) NULL,
	[PageName] [nvarchar](150) NULL,
	[Date] [datetime] NULL,
 CONSTRAINT [PK_ShopNum1_OperateLog] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
/****** 对象:  Table [dbo].[ShopNum1_OrderOperateLog]    脚本日期: 10/02/2009 19:00:17 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_OrderOperateLog](
	[Guid] [uniqueidentifier] NOT NULL,
	[OrderInfoGuid] [uniqueidentifier] NOT NULL,
	[CreateUser] [nvarchar](50) NOT NULL,
	[OderStatus] [int] NOT NULL CONSTRAINT [DF_ShopNum1_OrderOperateLog_OderStatus]  DEFAULT ((0)),
	[ShipmentStatus] [int] NOT NULL CONSTRAINT [DF_ShopNum1_OrderOperateLog_ShipmentStatus]  DEFAULT ((0)),
	[PaymentStatus] [int] NOT NULL CONSTRAINT [DF_ShopNum1_OrderOperateLog_PaymentStatus]  DEFAULT ((0)),
	[Memo] [nvarchar](500) NULL,
	[OperateDateTime] [datetime] NOT NULL,
	[IsDeleted] [int] NULL CONSTRAINT [DF_ShopNum1_OrderOperateLog_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_OrderOperateLog] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
/****** 对象:  Table [dbo].[ShopNum1_SalesPromotionProduct]    脚本日期: 10/02/2009 19:02:35 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_SalesPromotionProduct](
	[SalesPromotionInfoGuid] [uniqueidentifier] NOT NULL,
	[ProductGuid] [uniqueidentifier] NOT NULL,
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
 CONSTRAINT [PK_ShopNum1_SalesPromotionProduct] PRIMARY KEY CLUSTERED 
(
	[SalesPromotionInfoGuid] ASC,
	[ProductGuid] 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
/****** 对象:  Table [dbo].[ShopNum1_WholesalePrice]    脚本日期: 10/02/2009 19:03:33 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_WholesalePrice](
	[Guid] [uniqueidentifier] NOT NULL,
	[Amount] [int] NOT NULL CONSTRAINT [DF_ShopNum1_WholesalePrice_Amount]  DEFAULT ((0)),
	[Price] [decimal](18, 2) NOT NULL,
	[WholesaleInfoGuid] [uniqueidentifier] NOT NULL,
 CONSTRAINT [PK_ShopNum1_WholesalePrice] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
/****** 对象:  Table [dbo].[ShopNum1_SalesPromotionMemberRank]    脚本日期: 10/02/2009 19:02:33 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_SalesPromotionMemberRank](
	[SalesPromotionInfoGuid] [uniqueidentifier] NOT NULL,
	[MemberRankGuid] [uniqueidentifier] NOT NULL,
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
 CONSTRAINT [PK_ShopNum1_SalesPromotionMemberRank] PRIMARY KEY CLUSTERED 
(
	[SalesPromotionInfoGuid] ASC,
	[MemberRankGuid] 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
/****** 对象:  Table [dbo].[ShopNum1_SalesPromotionFavourTicket]    脚本日期: 10/02/2009 19:02:25 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_SalesPromotionFavourTicket](
	[SalesPromotionInfoGuid] [uniqueidentifier] NOT NULL,
	[FavourTicketGuid] [uniqueidentifier] NOT NULL,
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
 CONSTRAINT [PK_ShopNum1_SalesPromotionFavourTicket] PRIMARY KEY CLUSTERED 
(
	[SalesPromotionInfoGuid] ASC,
	[FavourTicketGuid] 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
/****** 对象:  Table [dbo].[ShopNum1_BuyAndGive]    脚本日期: 10/02/2009 18:56:18 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_BuyAndGive](
	[SalesPromotionInfoGuid] [uniqueidentifier] NOT NULL,
	[BuyNumber] [int] NOT NULL,
	[GiveNumber] [int] NOT NULL,
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
 CONSTRAINT [PK_ShopNum1_BuyAndGive_1] PRIMARY KEY CLUSTERED 
(
	[SalesPromotionInfoGuid] 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
/****** 对象:  Table [dbo].[ShopNum1_FullAndFavourTicket]    脚本日期: 10/02/2009 18:57:25 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_FullAndFavourTicket](
	[SalesPromotionInfoGuid] [uniqueidentifier] NOT NULL,
	[MinimalCost] [decimal](18, 2) NOT NULL,
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
 CONSTRAINT [PK_ShopNum1_FullAndFavourTicket_1] PRIMARY KEY CLUSTERED 
(
	[SalesPromotionInfoGuid] 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
/****** 对象:  Table [dbo].[ShopNum1_Collect]    脚本日期: 10/02/2009 18:56:29 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_Collect](
	[Guid] [uniqueidentifier] NOT NULL,
	[MemLoginID] [nvarchar](50) NOT NULL,
	[ProductGuid] [uniqueidentifier] NOT NULL,
	[CollectTime] [datetime] NOT NULL,
	[IsAttention] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Collect_IsAttention]  DEFAULT ((0)),
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Collect_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_Collect] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
/****** 对象:  Table [dbo].[ShopNum1_MessageBoard]    脚本日期: 10/02/2009 18:59:39 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_MessageBoard](
	[Guid] [uniqueidentifier] NOT NULL,
	[MemLoginID] [nvarchar](50) NULL,
	[MeaageType] [nvarchar](20) NULL,
	[Title] [nvarchar](250) NULL,
	[Content] [text] NULL,
	[SendTime] [datetime] NOT NULL,
	[ReplyUser] [nvarchar](50) NULL CONSTRAINT [DF_ShopNum1_MessageBoard_ReplyUser]  DEFAULT (NULL),
	[ReplyTime] [datetime] NULL,
	[ReplyContent] [text] NULL,
	[IsReply] [int] NOT NULL CONSTRAINT [DF_ShopNum1_MessageBoard_IsReply]  DEFAULT ((0)),
	[IsAudit] [int] NOT NULL CONSTRAINT [DF_ShopNum1_MessageBoard_IsAudit]  DEFAULT ((0)),
	[ModifyUser] [nvarchar](50) NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_MessageBoard_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_MessageBoard] PRIMARY KEY CLUSTERED 
(
	[Guid] 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]
GO
/****** 对象:  Table [dbo].[ShopNum1_Page]    脚本日期: 10/02/2009 19:00:53 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_Page](
	[Guid] [uniqueidentifier] NOT NULL,
	[Name] [nvarchar](250) NOT NULL,
	[OrderID] [int] NOT NULL,
	[OneID] [int] NOT NULL,
	[TwoID] [int] NOT NULL,
	[ThreeID] [int] NOT NULL,
	[Description] [nvarchar](100) NULL,
	[PageType] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Page_PageType]  DEFAULT ((0)),
	[PagePath] [nvarchar](250) NULL,
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Page_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_Page] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
/****** 对象:  Table [dbo].[ShopNum1_FullAndGift]    脚本日期: 10/02/2009 18:57:29 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_FullAndGift](
	[SalesPromotionInfoGuid] [uniqueidentifier] NOT NULL,
	[Cost] [decimal](18, 2) NOT NULL,
	[Count] [int] NOT NULL,
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
 CONSTRAINT [PK_ShopNum1_FullAndGift_1] PRIMARY KEY CLUSTERED 
(
	[SalesPromotionInfoGuid] 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
/****** 对象:  Table [dbo].[ShopNum1_OrganizBuyInfo]    脚本日期: 10/02/2009 19:00:34 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_OrganizBuyInfo](
	[Guid] [uniqueidentifier] NOT NULL,
	[ProductGuid] [uniqueidentifier] NOT NULL,
	[OriginalImge] [nvarchar](250) NULL CONSTRAINT [DF_ShopNum1_OrganizBuyInfo_OriginalImge]  DEFAULT (NULL),
	[StartTime] [datetime] NOT NULL,
	[EndTime] [datetime] NOT NULL,
	[RestrictCount] [int] NOT NULL CONSTRAINT [DF_ShopNum1_OrganizBuyInfo_ExtentPrice]  DEFAULT ((0)),
	[Deposit] [decimal](18, 2) NOT NULL CONSTRAINT [DF_ShopNum1_OrganizBuyInfo_Deposit]  DEFAULT ((0)),
	[PresentScore] [int] NOT NULL CONSTRAINT [DF_ShopNum1_OrganizBuyInfo_PresentScore]  DEFAULT ((0)),
	[PresentRankScore] [int] NOT NULL CONSTRAINT [DF_ShopNum1_OrganizBuyInfo_PresentRankScore]  DEFAULT ((0)),
	[Memo] [ntext] NULL,
	[IsEnd] [int] NOT NULL CONSTRAINT [DF_ShopNum1_OrganizBuyInfo_IsEnd]  DEFAULT ((0)),
	[OrderID] [int] NOT NULL CONSTRAINT [DF_ShopNum1_OrganizBuyInfo_OrderID]  DEFAULT ((0)),
	[SpeakForCount] [int] NOT NULL CONSTRAINT [DF_ShopNum1_OrganizBuyInfo_SpeakForCount]  DEFAULT ((0)),
	[OrderCount] [int] NOT NULL CONSTRAINT [DF_ShopNum1_OrganizBuyInfo_OrderCount]  DEFAULT ((0)),
	[CurrentPrice] [decimal](18, 2) NOT NULL CONSTRAINT [DF_ShopNum1_OrganizBuyInfo_CurrentPrice]  DEFAULT ((0)),
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_OrganizBuyInfo_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_OrganizBuyInfo] PRIMARY KEY CLUSTERED 
(
	[Guid] 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]
GO
/****** 对象:  Table [dbo].[ShopNum1_MessageInfo]    脚本日期: 10/02/2009 18:59:42 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_MessageInfo](
	[Guid] [uniqueidentifier] NOT NULL,
	[Title] [nvarchar](50) NULL,
	[Type] [nvarchar](50) NULL,
	[Content] [ntext] NULL,
	[MemLoginID] [nvarchar](50) NULL,
	[LoginID] [nvarchar](50) NULL,
	[CreateTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL,
 CONSTRAINT [PK_ShopNum1_MessageInfo] PRIMARY KEY CLUSTERED 
(
	[Guid] 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]
GO
/****** 对象:  Table [dbo].[ShopNum1_FullAndDiscount]    脚本日期: 10/02/2009 18:57:23 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_FullAndDiscount](
	[SalesPromotionInfoGuid] [uniqueidentifier] NOT NULL,
	[MinimalCost] [decimal](18, 2) NOT NULL,
	[DiscountMode] [int] NOT NULL CONSTRAINT [DF_ShopNum1_FullAndDiscount_DiscountMode]  DEFAULT ((0)),
	[Number] [decimal](18, 2) NOT NULL,
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
 CONSTRAINT [PK_ShopNum1_FullAndDiscount_1] PRIMARY KEY CLUSTERED 
(
	[SalesPromotionInfoGuid] 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
/****** 对象:  Table [dbo].[ShopNum1_ProductCategory]    脚本日期: 10/02/2009 19:01:51 ******/

SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
IF NOT EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[ShopNum1_ProductCategory]') AND type in (N'U'))
BEGIN
CREATE TABLE [dbo].[ShopNum1_ProductCategory](
	[ID] [int] NOT NULL,
	[Name] [nvarchar](50) NOT NULL,
	[Keywords] [nvarchar](200) NULL CONSTRAINT [DF_ShopNum1_ProductCategory_Keywords]  DEFAULT (NULL),
	[Description] [nvarchar](150) NULL CONSTRAINT [DF_ShopNum1_ProductCategory_Description]  DEFAULT (NULL),
	[OrderID] [int] NOT NULL,
	[IsShow] [int] NOT NULL CONSTRAINT [DF_ShopNum1_ProductCategory_IsShow]  DEFAULT ((1)),
	[CategoryLevel] [int] NOT NULL CONSTRAINT [DF_ShopNum1_ProductCategory_CategoryLevel]  DEFAULT ((0)),
	[FatherID] [int] NOT NULL,
	[Family] [nvarchar](250) NULL,
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_ProductCategory_IsDeleted]  DEFAULT ((0)),
	[IsDownLoad] [int] NOT NULL CONSTRAINT [DF_ShopNum1_ProductCategory_IsDownLoad]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_ProductCategory] PRIMARY KEY CLUSTERED 
(
	[ID] ASC
)WITH (IGNORE_DUP_KEY = OFF) ON [PRIMARY]
) ON [PRIMARY]
END

/****** 对象:  Table [dbo].[ShopNum1_FullAndScore]    脚本日期: 10/02/2009 18:57:32 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_FullAndScore](
	[SalesPromotionInfoGuid] [uniqueidentifier] NOT NULL,
	[MinimalCost] [decimal](18, 2) NOT NULL,
	[RankScore] [int] NOT NULL,
	[ExpendScore] [int] NOT NULL,
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
 CONSTRAINT [PK_ShopNum1_FullAndScore_1] PRIMARY KEY CLUSTERED 
(
	[SalesPromotionInfoGuid] 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
/****** 对象:  Table [dbo].[ShopNum1_FullAndFree]    脚本日期: 10/02/2009 18:57:27 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_FullAndFree](
	[SalesPromotionInfoGuid] [uniqueidentifier] NOT NULL,
	[MinimalCost] [decimal](18, 2) NOT NULL,
	[FreeItem] [int] NOT NULL CONSTRAINT [DF_ShopNum1_FullAndFree_FreeItem]  DEFAULT ((0)),
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
 CONSTRAINT [PK_ShopNum1_FullAndFree] PRIMARY KEY CLUSTERED 
(
	[SalesPromotionInfoGuid] 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
/****** 对象:  Table [dbo].[ShopNum1_Address]    脚本日期: 10/02/2009 18:55:07 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_Address](
	[Guid] [uniqueidentifier] NOT NULL,
	[Name] [nvarchar](50) NULL,
	[Email] [nvarchar](100) NULL,
	[Address] [nvarchar](250) NULL,
	[Postalcode] [nvarchar](20) NULL,
	[Tel] [nvarchar](20) NULL,
	[Mobile] [nvarchar](20) NULL,
	[IsDefault] [int] NOT NULL,
	[MemLoginID] [nvarchar](50) NOT NULL,
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Address_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_Address] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
/****** 对象:  Table [dbo].[ShopNum1_MemberRank]    脚本日期: 10/02/2009 18:59:24 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_MemberRank](
	[Guid] [uniqueidentifier] NOT NULL,
	[Name] [nvarchar](50) NOT NULL,
	[Score] [int] NOT NULL CONSTRAINT [DF_ShopNum1_MemberRank_Score]  DEFAULT ((0)),
	[PayoutCount] [int] NOT NULL CONSTRAINT [DF_ShopNum1_MemberRank_PayoutCount]  DEFAULT ((0)),
	[PayoutMoney] [decimal](18, 2) NOT NULL CONSTRAINT [DF_ShopNum1_MemberRank_PayoutMoney]  DEFAULT ((0)),
	[Discount] [decimal](18, 2) NOT NULL CONSTRAINT [DF_ShopNum1_MemberRank_Discount]  DEFAULT ((0)),
	[IsDefault] [int] NOT NULL CONSTRAINT [DF_ShopNum1_MemberRank_IsDefault]  DEFAULT ((0)),
	[Memo] [nvarchar](250) NULL,
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_MemberRank_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_MemberRank] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
/****** 对象:  Table [dbo].[ShopNum1_AdvancePaymentApplyLog]    脚本日期: 10/02/2009 18:55:18 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_AdvancePaymentApplyLog](
	[Guid] [uniqueidentifier] NOT NULL,
	[OperateType] [nvarchar](20) NOT NULL,
	[CurrentAdvancePayment] [decimal](18, 2) NOT NULL,
	[OperateMoney] [decimal](18, 2) NOT NULL,
	[Date] [datetime] NOT NULL,
	[OperateStatus] [int] NOT NULL CONSTRAINT [DF_ShopNum1_AdvancePaymentApplyLog_OperateStatus]  DEFAULT ((0)),
	[Memo] [nvarchar](4000) NULL CONSTRAINT [DF_ShopNum1_AdvancePaymentApplyLog_Memo]  DEFAULT (NULL),
	[UserMemo] [nvarchar](4000) NULL,
	[MemLoginID] [nvarchar](50) NOT NULL,
	[PaymentGuid] [uniqueidentifier] NULL CONSTRAINT [DF_ShopNum1_AdvancePaymentApplyLog_PaymentGuid]  DEFAULT (NULL),
	[PaymentName] [nvarchar](100) NULL CONSTRAINT [DF_ShopNum1_AdvancePaymentApplyLog_PaymentName]  DEFAULT (NULL),
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_AdvancePaymentApplyLog_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_AdvancePaymentApplyLog] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
/****** 对象:  Table [dbo].[ShopNum1_OutOfStock]    脚本日期: 10/02/2009 19:00:42 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_OutOfStock](
	[Guid] [uniqueidentifier] NOT NULL,
	[MemLoginID] [nvarchar](50) NOT NULL,
	[ProductGuid] [uniqueidentifier] NOT NULL,
	[SendTime] [datetime] NOT NULL,
	[Number] [int] NOT NULL CONSTRAINT [DF_ShopNum1_OutOfStock_Number]  DEFAULT ((0)),
	[Name] [nvarchar](50) NOT NULL,
	[Email] [nvarchar](100) NOT NULL,
	[Tel] [nvarchar](20) NULL,
	[BookMemo] [nvarchar](250) NULL CONSTRAINT [DF_ShopNum1_OutOfStock_BookMemo]  DEFAULT (NULL),
	[ReplyUser] [nvarchar](50) NULL CONSTRAINT [DF_ShopNum1_OutOfStock_ReplyUser]  DEFAULT (NULL),
	[ReplyTime] [datetime] NULL CONSTRAINT [DF_ShopNum1_OutOfStock_ReplyTime]  DEFAULT (NULL),
	[ReplyMemo] [nvarchar](250) NULL CONSTRAINT [DF_ShopNum1_OutOfStock_ReplyMemo]  DEFAULT (NULL),
	[IsReply] [int] NOT NULL CONSTRAINT [DF_ShopNum1_OutOfStock_IsReply]  DEFAULT ((0)),
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_OutOfStock_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_OutOfStock] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
/****** 对象:  Table [dbo].[ShopNum1_ProductMemberRankPrice]    脚本日期: 10/02/2009 19:02:05 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_ProductMemberRankPrice](
	[Guid] [uniqueidentifier] NOT NULL,
	[ProductGuid] [uniqueidentifier] NOT NULL,
	[MemberRankGuid] [uniqueidentifier] NOT NULL,
	[Price] [decimal](18, 2) NOT NULL CONSTRAINT [DF_ShopNum1_ProductMemberRankPrice_Price]  DEFAULT ((0)),
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL,
 CONSTRAINT [PK_ShopNum1_ProductMemberRankPrice] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
/****** 对象:  Table [dbo].[ShopNum1_Region]    脚本日期: 10/02/2009 19:02:18 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_Region](
	[ID] [int] IDENTITY(1,1) NOT NULL,
	[Name] [nvarchar](50) NULL,
	[OrderID] [int] NOT NULL,
	[RegionLevel] [int] NOT NULL,
	[FatherID] [int] NOT NULL,
	[Family] [nvarchar](250) NOT NULL,
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Area_IsDelete]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_Region] 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]
GO
/****** 对象:  Table [dbo].[ShopNum1_Product]    脚本日期: 10/02/2009 19:01:29 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_Product](
	[Guid] [uniqueidentifier] NOT NULL,
	[Name] [nvarchar](100) NOT NULL,
	[OriginalImge] [nvarchar](250) NOT NULL,
	[ThumbImage] [nvarchar](250) NULL,
	[SmallImage] [nvarchar](250) NULL,
	[RepertoryNumber] [nvarchar](50) NOT NULL,
	[Weight] [decimal](18, 2) NOT NULL CONSTRAINT [DF_ShopNum1_Product_Weight]  DEFAULT ((0)),
	[RepertoryCount] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Product_RepertoryCount]  DEFAULT ((0)),
	[UnitName] [nvarchar](20) NOT NULL,
	[RepertoryAlertCount] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Product_RepertoryAlertCount]  DEFAULT ((0)),
	[PresentScore] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Product_PresentScore]  DEFAULT ((0)),
	[PresentRankScore] [int] NOT NULL,
	[SocreIntegral] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Product_SocreIntegral]  DEFAULT ((0)),
	[LimitBuyCount] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Product_LimitBuyCount]  DEFAULT ((0)),
	[CostPrice] [decimal](18, 2) NOT NULL CONSTRAINT [DF_ShopNum1_Product_CostPrice]  DEFAULT ((0)),
	[MarketPrice] [decimal](18, 2) NOT NULL CONSTRAINT [DF_ShopNum1_Product_MarketPrice]  DEFAULT ((0)),
	[ShopPrice] [decimal](18, 2) NOT NULL CONSTRAINT [DF_ShopNum1_Product_ShopPrice]  DEFAULT ((0)),
	[Brief] [nvarchar](250) NOT NULL,
	[Memo] [ntext] NULL CONSTRAINT [DF_ShopNum1_Product_Memo]  DEFAULT (NULL),
	[Detail] [ntext] NULL CONSTRAINT [DF_ShopNum1_Product_Detail]  DEFAULT (NULL),
	[ClickCount] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Product_ClickCount]  DEFAULT ((1)),
	[CollectCount] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Product_CollectCount]  DEFAULT ((0)),
	[BuyCount] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Product_BuyCount]  DEFAULT ((0)),
	[CommentCount] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Product_CommentCount]  DEFAULT ((0)),
	[ReferCount] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Product_ReferCount]  DEFAULT ((0)),
	[IsSaled] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Product_IsSaled]  DEFAULT ((0)),
	[IsBest] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Product_IsBest]  DEFAULT ((0)),
	[IsNew] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Product_IsNew]  DEFAULT ((1)),
	[IsHot] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Product_IsHot]  DEFAULT ((0)),
	[IsRecommend] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Product_IsRecommend]  DEFAULT ((0)),
	[IsReal] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Product_IsReal]  DEFAULT ((1)),
	[IsOnlySaled] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Product_IsOnlySaled]  DEFAULT ((1)),
	[Title] [nvarchar](150) NULL,
	[Description] [nvarchar](150) NULL,
	[Keywords] [nvarchar](200) NULL,
	[OrderID] [int] NOT NULL,
	[SupplierGuid] [uniqueidentifier] NULL,
	[BrandGuid] [uniqueidentifier] NULL,
	[BrandName] [nvarchar](50) NULL,
	[ProductCategoryID] [int] NULL,
	[ProductTypeGuid] [uniqueidentifier] NULL,
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Product_IsDeleted]  DEFAULT ((0)),
	[SaleNumber] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Product_SaleNumber]  DEFAULT ((0)),
	[IsDownLoad] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Product_IsDownLoad]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_Product] PRIMARY KEY CLUSTERED 
(
	[Guid] 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]
GO
/****** 对象:  Table [dbo].[ShopNum1_Brand]    脚本日期: 10/02/2009 18:56:16 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_Brand](
	[Guid] [uniqueidentifier] NOT NULL,
	[Name] [nvarchar](50) NOT NULL,
	[Logo] [nvarchar](250) NOT NULL,
	[WebSite] [nvarchar](100) NOT NULL,
	[OrderID] [int] NOT NULL,
	[Keywords] [nvarchar](200) NULL,
	[IsShow] [int] NOT NULL,
	[Remark] [ntext] NOT NULL,
	[Description] [nvarchar](150) NOT NULL,
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Brand_IsDeleted]  DEFAULT ((0)),
	[IsDownLoad] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Brand_IsDownLoad]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_Brand] PRIMARY KEY CLUSTERED 
(
	[Guid] 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]
GO
/****** 对象:  Table [dbo].[ShopNum1_DispatchRegion]    脚本日期: 10/02/2009 18:56:56 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_DispatchRegion](
	[Guid] [uniqueidentifier] NOT NULL,
	[Name] [nvarchar](50) NOT NULL,
	[OrderID] [int] NOT NULL,
	[Memo] [nvarchar](1000) NOT NULL,
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_Num1_RegionGroup_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_DispatchRegion] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
/****** 对象:  Table [dbo].[ShopNum1_AdvancePaymentModifyLog]    脚本日期: 10/02/2009 18:55:28 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_AdvancePaymentModifyLog](
	[Guid] [uniqueidentifier] NOT NULL,
	[OperateType] [int] NOT NULL,
	[CurrentAdvancePayment] [decimal](18, 2) NOT NULL,
	[OperateMoney] [decimal](18, 2) NOT NULL,
	[LastOperateMoney] [decimal](18, 2) NOT NULL,
	[Date] [datetime] NOT NULL,
	[Memo] [nvarchar](250) NULL CONSTRAINT [DF_ShopNum1_AdvancePaymentModifyLog_Memo]  DEFAULT (NULL),
	[MemLoginID] [nvarchar](50) NOT NULL,
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_AdvancePaymentModifyLog_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_AdvancePaymentModifyLog] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
/****** 对象:  Table [dbo].[ShopNum1_DispatchItem]    脚本日期: 10/02/2009 18:56:42 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_DispatchItem](
	[Guid] [uniqueidentifier] NOT NULL,
	[ItemName] [nvarchar](50) NOT NULL,
	[ItemCode] [nvarchar](50) NOT NULL,
	[ItemValue] [decimal](18, 2) NOT NULL,
	[DispatchMode] [uniqueidentifier] NOT NULL,
	[CreateUser] [nvarchar](50) NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_DispatchItem_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_DispatchItem] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
/****** 对象:  Table [dbo].[ShopNum1_Pack]    脚本日期: 10/02/2009 19:00:47 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_Pack](
	[Guid] [uniqueidentifier] NOT NULL,
	[Name] [nvarchar](50) NOT NULL,
	[Cost] [decimal](18, 2) NOT NULL,
	[FreeLimit] [decimal](18, 2) NOT NULL,
	[PackImagePath] [nvarchar](250) NOT NULL,
	[Description] [nvarchar](100) NOT NULL,
	[OrderID] [int] NOT NULL,
	[IfUse] [int] NOT NULL CONSTRAINT [DF_ShopNum1_GoodPack_IfUse]  DEFAULT ((0)),
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_GoodPack_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_GoodPack] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
/****** 对象:  Table [dbo].[ShopNum1_Ad]    脚本日期: 10/02/2009 18:55:02 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_Ad](
	[Guid] [uniqueidentifier] NOT NULL,
	[Name] [nvarchar](50) NOT NULL,
	[Type] [int] NOT NULL,
	[AdPositionGuid] [uniqueidentifier] NOT NULL,
	[StartTime] [datetime] NOT NULL,
	[EndTime] [datetime] NOT NULL,
	[Link] [nvarchar](150) NULL CONSTRAINT [DF_ShopNum1_Ad_Link]  DEFAULT (NULL),
	[OriginalImge] [nvarchar](250) NULL CONSTRAINT [DF_ShopNum1_Ad_OriginalImge]  DEFAULT (NULL),
	[Flash] [nvarchar](250) NULL CONSTRAINT [DF_ShopNum1_Ad_Flash]  DEFAULT (NULL),
	[Code] [ntext] NULL CONSTRAINT [DF_ShopNum1_Ad_Code]  DEFAULT (NULL),
	[Content] [ntext] NULL,
	[IsOpen] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Ad_IsOpen]  DEFAULT ((1)),
	[LinkMan] [nvarchar](50) NULL CONSTRAINT [DF_ShopNum1_Ad_LinkMan]  DEFAULT (NULL),
	[Email] [nvarchar](100) NULL CONSTRAINT [DF_ShopNum1_Ad_Email]  DEFAULT (NULL),
	[Tel] [nvarchar](20) NULL CONSTRAINT [DF_ShopNum1_Ad_Tel]  DEFAULT (NULL),
	[Count] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Ad_Count]  DEFAULT ((0)),
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Ad_IsDeleted]  DEFAULT ((0)),
	[JsFileName] [nvarchar](50) NULL,
 CONSTRAINT [PK_ShopNum1_Ad] PRIMARY KEY CLUSTERED 
(
	[Guid] 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]
GO
/****** 对象:  Table [dbo].[ShopNum1_DispatchItemRegion]    脚本日期: 10/02/2009 18:56:47 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_DispatchItemRegion](
	[Guid] [uniqueidentifier] NOT NULL,
	[ItemName] [nvarchar](50) NOT NULL,
	[ItemCode] [nvarchar](50) NOT NULL,
	[ItemValue] [decimal](18, 2) NOT NULL,
	[DispatchRegionGuid] [uniqueidentifier] NOT NULL,
	[DispatchMode] [uniqueidentifier] NOT NULL,
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_DispatchItemRegion_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_DispatchItemRegion] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
/****** 对象:  Table [dbo].[ShopNum1_DispatchMode]    脚本日期: 10/02/2009 18:56:52 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_DispatchMode](
	[Guid] [uniqueidentifier] NOT NULL,
	[Name] [nvarchar](50) NOT NULL,
	[Remark] [nvarchar](1000) NULL,
	[IsPayArrived] [int] NOT NULL CONSTRAINT [DF_ShopNum1_DispatchMode_IsPayArrived]  DEFAULT ((0)),
	[SafeCost] [decimal](18, 2) NOT NULL,
	[Formula] [nvarchar](100) NULL,
	[OrderID] [int] NOT NULL,
	[CreateUser] [nvarchar](50) NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_DispatchMode_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_DispatchMode] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
/****** 对象:  Table [dbo].[ShopNum1_AdvancePaymentFreezeLog]    脚本日期: 10/02/2009 18:55:23 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_AdvancePaymentFreezeLog](
	[Guid] [uniqueidentifier] NOT NULL,
	[OperateType] [int] NOT NULL,
	[CurrentAdvancePayment] [decimal](18, 2) NOT NULL,
	[OperateMoney] [decimal](18, 2) NOT NULL,
	[LastOperateMoney] [decimal](18, 2) NOT NULL,
	[Date] [datetime] NOT NULL,
	[Memo] [nvarchar](250) NULL CONSTRAINT [DF_ShopNum1_AdvancePaymentFreezeLog_Memo]  DEFAULT (NULL),
	[MemLoginID] [nvarchar](50) NOT NULL,
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_AdvancePaymentFreezeLog_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_AdvancePaymentFreezeLog] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
/****** 对象:  Table [dbo].[ShopNum1_KeyWords]    脚本日期: 10/02/2009 18:58:18 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_KeyWords](
	[Guid] [uniqueidentifier] NOT NULL,
	[Name] [nvarchar](50) NULL,
	[Type] [int] NOT NULL CONSTRAINT [DF_ShopNum1_KeyWords_Type]  DEFAULT ((0)),
	[Count] [int] NOT NULL CONSTRAINT [DF_ShopNum1_KeyWords_Count]  DEFAULT ((0)),
	[IfShow] [int] NOT NULL CONSTRAINT [DF_ShopNum1_KeyWords_IfShow]  DEFAULT ((0)),
	[CreateUser] [nvarchar](50) NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_KeyWords_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_KeyWords] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
/****** 对象:  Table [dbo].[ShopNum1_HelpType]    脚本日期: 10/02/2009 18:58:01 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_HelpType](
	[Guid] [uniqueidentifier] NOT NULL,
	[Name] [nvarchar](50) NOT NULL,
	[Remark] [nvarchar](500) NOT NULL,
	[OrderID] [int] NOT NULL CONSTRAINT [DF_ShopNum1_HelpType_OrderID]  DEFAULT ((0)),
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_HelpType_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_HelpType] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
/****** 对象:  Table [dbo].[ShopNum1_ImagePath]    脚本日期: 10/02/2009 18:58:13 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_ImagePath](
	[OriginalImagePath] [nvarchar](250) NOT NULL,
	[OtherImagePath] [nvarchar](250) NOT NULL,
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL
) ON [PRIMARY]
GO
/****** 对象:  Table [dbo].[ShopNum1_ProductType]    脚本日期: 10/02/2009 19:02:09 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_ProductType](
	[Guid] [uniqueidentifier] NOT NULL,
	[Name] [nvarchar](50) NOT NULL,
	[AttributeGroup] [ntext] NULL CONSTRAINT [DF_ShopNum1_ProductType_AttributeGroup]  DEFAULT (NULL),
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_ProductType_IsDeleted]  DEFAULT ((0)),
	[IsDownLoad] [int] NOT NULL CONSTRAINT [DF_ShopNum1_ProductType_IsDownLoad]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_ProductType] PRIMARY KEY CLUSTERED 
(
	[Guid] 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]
GO
/****** 对象:  Table [dbo].[ShopNum1_GuidInfo]    脚本日期: 10/02/2009 18:57:51 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_GuidInfo](
	[Guid] [uniqueidentifier] NOT NULL,
	[Name] [nvarchar](50) NOT NULL,
	[OriginalImge] [nvarchar](250) NOT NULL,
	[Description] [ntext] NOT NULL,
	[OrderID] [int] NOT NULL CONSTRAINT [DF_ShopNum1_GuidBuyInfo_OrderID]  DEFAULT ((1)),
	[IsShow] [int] NOT NULL,
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_GuidBuyInfo_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_GuidBuyInfo] PRIMARY KEY CLUSTERED 
(
	[Guid] 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]
GO
/****** 对象:  Table [dbo].[ShopNum1_Unit]    脚本日期: 10/02/2009 19:03:01 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ShopNum1_Unit](
	[Guid] [uniqueidentifier] NOT NULL,
	[Code] [nvarchar](10) NOT NULL,
	[Name] [nvarchar](20) NOT NULL,
	[CreateUser] [nvarchar](50) NOT NULL,
	[CreateTime] [datetime] NOT NULL,
	[ModifyUser] [nvarchar](50) NOT NULL,
	[ModifyTime] [datetime] NOT NULL,
	[IsDeleted] [int] NOT NULL CONSTRAINT [DF_ShopNum1_Unit_IsDeleted]  DEFAULT ((0)),
 CONSTRAINT [PK_ShopNum1_Unit] PRIMARY KEY CLUSTERED 
(
	[Guid] 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
