1 | USE [master]
|
---|
2 | GO
|
---|
3 |
|
---|
4 | /****** Object: Database [HeuristicLab.PluginStore] Script Date: 02/08/2010 19:01:45 ******/
|
---|
5 | CREATE DATABASE [HeuristicLab.PluginStore] ON PRIMARY
|
---|
6 | ( NAME = N'HeuristicLab.PluginStore', FILENAME = N'C:\Program Files\Microsoft SQL Server\MSSQL.1\MSSQL\DATA\HeuristicLab.PluginStore.mdf' , SIZE = 22528KB , MAXSIZE = UNLIMITED, FILEGROWTH = 1024KB )
|
---|
7 | LOG ON
|
---|
8 | ( NAME = N'HeuristicLab.PluginStore_log', FILENAME = N'C:\Program Files\Microsoft SQL Server\MSSQL.1\MSSQL\DATA\HeuristicLab.PluginStore_log.ldf' , SIZE = 2816KB , MAXSIZE = 2048GB , FILEGROWTH = 10%)
|
---|
9 | GO
|
---|
10 |
|
---|
11 | ALTER DATABASE [HeuristicLab.PluginStore] SET COMPATIBILITY_LEVEL = 90
|
---|
12 | GO
|
---|
13 |
|
---|
14 | IF (1 = FULLTEXTSERVICEPROPERTY('IsFullTextInstalled'))
|
---|
15 | begin
|
---|
16 | EXEC [HeuristicLab.PluginStore].[dbo].[sp_fulltext_database] @action = 'enable'
|
---|
17 | end
|
---|
18 | GO
|
---|
19 |
|
---|
20 | ALTER DATABASE [HeuristicLab.PluginStore] SET ANSI_NULL_DEFAULT OFF
|
---|
21 | GO
|
---|
22 |
|
---|
23 | ALTER DATABASE [HeuristicLab.PluginStore] SET ANSI_NULLS OFF
|
---|
24 | GO
|
---|
25 |
|
---|
26 | ALTER DATABASE [HeuristicLab.PluginStore] SET ANSI_PADDING OFF
|
---|
27 | GO
|
---|
28 |
|
---|
29 | ALTER DATABASE [HeuristicLab.PluginStore] SET ANSI_WARNINGS OFF
|
---|
30 | GO
|
---|
31 |
|
---|
32 | ALTER DATABASE [HeuristicLab.PluginStore] SET ARITHABORT OFF
|
---|
33 | GO
|
---|
34 |
|
---|
35 | ALTER DATABASE [HeuristicLab.PluginStore] SET AUTO_CLOSE OFF
|
---|
36 | GO
|
---|
37 |
|
---|
38 | ALTER DATABASE [HeuristicLab.PluginStore] SET AUTO_CREATE_STATISTICS ON
|
---|
39 | GO
|
---|
40 |
|
---|
41 | ALTER DATABASE [HeuristicLab.PluginStore] SET AUTO_SHRINK OFF
|
---|
42 | GO
|
---|
43 |
|
---|
44 | ALTER DATABASE [HeuristicLab.PluginStore] SET AUTO_UPDATE_STATISTICS ON
|
---|
45 | GO
|
---|
46 |
|
---|
47 | ALTER DATABASE [HeuristicLab.PluginStore] SET CURSOR_CLOSE_ON_COMMIT OFF
|
---|
48 | GO
|
---|
49 |
|
---|
50 | ALTER DATABASE [HeuristicLab.PluginStore] SET CURSOR_DEFAULT GLOBAL
|
---|
51 | GO
|
---|
52 |
|
---|
53 | ALTER DATABASE [HeuristicLab.PluginStore] SET CONCAT_NULL_YIELDS_NULL OFF
|
---|
54 | GO
|
---|
55 |
|
---|
56 | ALTER DATABASE [HeuristicLab.PluginStore] SET NUMERIC_ROUNDABORT OFF
|
---|
57 | GO
|
---|
58 |
|
---|
59 | ALTER DATABASE [HeuristicLab.PluginStore] SET QUOTED_IDENTIFIER OFF
|
---|
60 | GO
|
---|
61 |
|
---|
62 | ALTER DATABASE [HeuristicLab.PluginStore] SET RECURSIVE_TRIGGERS OFF
|
---|
63 | GO
|
---|
64 |
|
---|
65 | ALTER DATABASE [HeuristicLab.PluginStore] SET DISABLE_BROKER
|
---|
66 | GO
|
---|
67 |
|
---|
68 | ALTER DATABASE [HeuristicLab.PluginStore] SET AUTO_UPDATE_STATISTICS_ASYNC OFF
|
---|
69 | GO
|
---|
70 |
|
---|
71 | ALTER DATABASE [HeuristicLab.PluginStore] SET DATE_CORRELATION_OPTIMIZATION OFF
|
---|
72 | GO
|
---|
73 |
|
---|
74 | ALTER DATABASE [HeuristicLab.PluginStore] SET TRUSTWORTHY OFF
|
---|
75 | GO
|
---|
76 |
|
---|
77 | ALTER DATABASE [HeuristicLab.PluginStore] SET ALLOW_SNAPSHOT_ISOLATION OFF
|
---|
78 | GO
|
---|
79 |
|
---|
80 | ALTER DATABASE [HeuristicLab.PluginStore] SET PARAMETERIZATION SIMPLE
|
---|
81 | GO
|
---|
82 |
|
---|
83 | ALTER DATABASE [HeuristicLab.PluginStore] SET READ_COMMITTED_SNAPSHOT OFF
|
---|
84 | GO
|
---|
85 |
|
---|
86 | ALTER DATABASE [HeuristicLab.PluginStore] SET READ_WRITE
|
---|
87 | GO
|
---|
88 |
|
---|
89 | ALTER DATABASE [HeuristicLab.PluginStore] SET RECOVERY SIMPLE
|
---|
90 | GO
|
---|
91 |
|
---|
92 | ALTER DATABASE [HeuristicLab.PluginStore] SET MULTI_USER
|
---|
93 | GO
|
---|
94 |
|
---|
95 | ALTER DATABASE [HeuristicLab.PluginStore] SET PAGE_VERIFY CHECKSUM
|
---|
96 | GO
|
---|
97 |
|
---|
98 | ALTER DATABASE [HeuristicLab.PluginStore] SET DB_CHAINING OFF
|
---|
99 | GO
|
---|
100 |
|
---|
101 | USE [HeuristicLab.PluginStore]
|
---|
102 | GO
|
---|
103 |
|
---|
104 | /****** Object: Table [dbo].[Dependencies] Script Date: 02/08/2010 19:02:19 ******/
|
---|
105 | SET ANSI_NULLS ON
|
---|
106 | GO
|
---|
107 |
|
---|
108 | SET QUOTED_IDENTIFIER ON
|
---|
109 | GO
|
---|
110 |
|
---|
111 | CREATE TABLE [dbo].[Dependencies](
|
---|
112 | [PluginId] [bigint] NOT NULL,
|
---|
113 | [DependencyId] [bigint] NOT NULL,
|
---|
114 | CONSTRAINT [PK_Dependencies] PRIMARY KEY CLUSTERED
|
---|
115 | (
|
---|
116 | [PluginId] ASC,
|
---|
117 | [DependencyId] ASC
|
---|
118 | )WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY]
|
---|
119 | ) ON [PRIMARY]
|
---|
120 |
|
---|
121 | GO
|
---|
122 |
|
---|
123 | ALTER TABLE [dbo].[Dependencies] WITH CHECK ADD CONSTRAINT [FK_Dependencies_Plugin] FOREIGN KEY([DependencyId])
|
---|
124 | REFERENCES [dbo].[Plugin] ([Id])
|
---|
125 | GO
|
---|
126 |
|
---|
127 | ALTER TABLE [dbo].[Dependencies] CHECK CONSTRAINT [FK_Dependencies_Plugin]
|
---|
128 | GO
|
---|
129 |
|
---|
130 | ALTER TABLE [dbo].[Dependencies] WITH CHECK ADD CONSTRAINT [FK_Dependencies_Plugin2] FOREIGN KEY([PluginId])
|
---|
131 | REFERENCES [dbo].[Plugin] ([Id])
|
---|
132 | GO
|
---|
133 |
|
---|
134 | ALTER TABLE [dbo].[Dependencies] CHECK CONSTRAINT [FK_Dependencies_Plugin2]
|
---|
135 | GO
|
---|
136 |
|
---|
137 |
|
---|
138 | USE [HeuristicLab.PluginStore]
|
---|
139 | GO
|
---|
140 |
|
---|
141 | /****** Object: Table [dbo].[Plugin] Script Date: 02/08/2010 19:02:48 ******/
|
---|
142 | SET ANSI_NULLS ON
|
---|
143 | GO
|
---|
144 |
|
---|
145 | SET QUOTED_IDENTIFIER ON
|
---|
146 | GO
|
---|
147 |
|
---|
148 | CREATE TABLE [dbo].[Plugin](
|
---|
149 | [Id] [bigint] IDENTITY(1,1) NOT NULL,
|
---|
150 | [Name] [nvarchar](300) NOT NULL,
|
---|
151 | [Version] [nvarchar](50) NOT NULL,
|
---|
152 | CONSTRAINT [PK_Plugin] PRIMARY KEY CLUSTERED
|
---|
153 | (
|
---|
154 | [Id] ASC
|
---|
155 | )WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY],
|
---|
156 | CONSTRAINT [IX_Plugin_NameVersion] UNIQUE NONCLUSTERED
|
---|
157 | (
|
---|
158 | [Name] ASC,
|
---|
159 | [Version] ASC
|
---|
160 | )WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY]
|
---|
161 | ) ON [PRIMARY]
|
---|
162 |
|
---|
163 | GO
|
---|
164 |
|
---|
165 |
|
---|
166 | USE [HeuristicLab.PluginStore]
|
---|
167 | GO
|
---|
168 |
|
---|
169 | /****** Object: Table [dbo].[PluginPackage] Script Date: 02/08/2010 19:02:53 ******/
|
---|
170 | SET ANSI_NULLS ON
|
---|
171 | GO
|
---|
172 |
|
---|
173 | SET QUOTED_IDENTIFIER ON
|
---|
174 | GO
|
---|
175 |
|
---|
176 | CREATE TABLE [dbo].[PluginPackage](
|
---|
177 | [PluginId] [bigint] NOT NULL,
|
---|
178 | [FileName] [text] NOT NULL,
|
---|
179 | [Data] [image] NOT NULL,
|
---|
180 | CONSTRAINT [PK_PluginPackage] PRIMARY KEY CLUSTERED
|
---|
181 | (
|
---|
182 | [PluginId] ASC
|
---|
183 | )WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY]
|
---|
184 | ) ON [PRIMARY] TEXTIMAGE_ON [PRIMARY]
|
---|
185 |
|
---|
186 | GO
|
---|
187 |
|
---|
188 | ALTER TABLE [dbo].[PluginPackage] WITH CHECK ADD CONSTRAINT [FK_PluginPackage_Plugin] FOREIGN KEY([PluginId])
|
---|
189 | REFERENCES [dbo].[Plugin] ([Id])
|
---|
190 | GO
|
---|
191 |
|
---|
192 | ALTER TABLE [dbo].[PluginPackage] CHECK CONSTRAINT [FK_PluginPackage_Plugin]
|
---|
193 | GO
|
---|
194 |
|
---|
195 |
|
---|
196 |
|
---|
197 | USE [HeuristicLab.PluginStore]
|
---|
198 | GO
|
---|
199 |
|
---|
200 | /****** Object: Table [dbo].[Product] Script Date: 02/08/2010 19:02:56 ******/
|
---|
201 | SET ANSI_NULLS ON
|
---|
202 | GO
|
---|
203 |
|
---|
204 | SET QUOTED_IDENTIFIER ON
|
---|
205 | GO
|
---|
206 |
|
---|
207 | CREATE TABLE [dbo].[Product](
|
---|
208 | [Id] [bigint] IDENTITY(1,1) NOT NULL,
|
---|
209 | [Name] [nvarchar](300) NOT NULL,
|
---|
210 | [Version] [nvarchar](50) NOT NULL,
|
---|
211 | CONSTRAINT [PK_Product] PRIMARY KEY CLUSTERED
|
---|
212 | (
|
---|
213 | [Id] ASC
|
---|
214 | )WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY],
|
---|
215 | CONSTRAINT [IX_Product_NameVersion] UNIQUE NONCLUSTERED
|
---|
216 | (
|
---|
217 | [Name] ASC,
|
---|
218 | [Version] ASC
|
---|
219 | )WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY]
|
---|
220 | ) ON [PRIMARY]
|
---|
221 |
|
---|
222 | GO
|
---|
223 |
|
---|
224 |
|
---|
225 | USE [HeuristicLab.PluginStore]
|
---|
226 | GO
|
---|
227 |
|
---|
228 | /****** Object: Table [dbo].[ProductPlugin] Script Date: 02/08/2010 19:03:01 ******/
|
---|
229 | SET ANSI_NULLS ON
|
---|
230 | GO
|
---|
231 |
|
---|
232 | SET QUOTED_IDENTIFIER ON
|
---|
233 | GO
|
---|
234 |
|
---|
235 | CREATE TABLE [dbo].[ProductPlugin](
|
---|
236 | [ProductId] [bigint] NOT NULL,
|
---|
237 | [PluginId] [bigint] NOT NULL,
|
---|
238 | CONSTRAINT [PK_ProductPlugin] PRIMARY KEY CLUSTERED
|
---|
239 | (
|
---|
240 | [ProductId] ASC,
|
---|
241 | [PluginId] ASC
|
---|
242 | )WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY]
|
---|
243 | ) ON [PRIMARY]
|
---|
244 |
|
---|
245 | GO
|
---|
246 |
|
---|
247 | ALTER TABLE [dbo].[ProductPlugin] WITH CHECK ADD CONSTRAINT [FK_ProductPlugin_Plugin] FOREIGN KEY([PluginId])
|
---|
248 | REFERENCES [dbo].[Plugin] ([Id])
|
---|
249 | GO
|
---|
250 |
|
---|
251 | ALTER TABLE [dbo].[ProductPlugin] CHECK CONSTRAINT [FK_ProductPlugin_Plugin]
|
---|
252 | GO
|
---|
253 |
|
---|
254 | ALTER TABLE [dbo].[ProductPlugin] WITH CHECK ADD CONSTRAINT [FK_ProductPlugin_Product] FOREIGN KEY([ProductId])
|
---|
255 | REFERENCES [dbo].[Product] ([Id])
|
---|
256 | GO
|
---|
257 |
|
---|
258 | ALTER TABLE [dbo].[ProductPlugin] CHECK CONSTRAINT [FK_ProductPlugin_Product]
|
---|
259 | GO
|
---|
260 |
|
---|
261 |
|
---|