aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Data/SQLite/Resources/AssetStore.migrations
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Data/SQLite/Resources/AssetStore.migrations')
-rw-r--r--OpenSim/Data/SQLite/Resources/AssetStore.migrations66
1 files changed, 66 insertions, 0 deletions
diff --git a/OpenSim/Data/SQLite/Resources/AssetStore.migrations b/OpenSim/Data/SQLite/Resources/AssetStore.migrations
new file mode 100644
index 0000000..bc11e13
--- /dev/null
+++ b/OpenSim/Data/SQLite/Resources/AssetStore.migrations
@@ -0,0 +1,66 @@
1:VERSION 1
2
3BEGIN TRANSACTION;
4CREATE TABLE assets(
5 UUID varchar(255) primary key,
6 Name varchar(255),
7 Description varchar(255),
8 Type integer,
9 InvType integer,
10 Local integer,
11 Temporary integer,
12 Data blob);
13
14COMMIT;
15
16:VERSION 2
17
18BEGIN TRANSACTION;
19
20CREATE TEMPORARY TABLE assets_backup(UUID,Name,Description,Type,Local,Temporary,Data);
21INSERT INTO assets_backup SELECT UUID,Name,Description,Type,Local,Temporary,Data FROM assets;
22DROP TABLE assets;
23CREATE TABLE assets(UUID,Name,Description,Type,Local,Temporary,Data);
24INSERT INTO assets SELECT UUID,Name,Description,Type,Local,Temporary,Data FROM assets_backup;
25DROP TABLE assets_backup;
26
27COMMIT;
28
29:VERSION 3
30
31DELETE FROM assets WHERE UUID = 'dc4b9f0bd00845c696a401dd947ac621'
32
33:VERSION 4
34
35BEGIN;
36
37update assets
38 set UUID = substr(UUID, 1, 8) || "-" || substr(UUID, 9, 4) || "-" || substr(UUID, 13, 4) || "-" || substr(UUID, 17, 4) || "-" || substr(UUID, 21, 12)
39 where UUID not like '%-%';
40
41COMMIT;
42
43:VERSION 5
44
45BEGIN TRANSACTION;
46
47CREATE TEMPORARY TABLE assets_backup(UUID,Name,Description,Type,Local,Temporary,Data);
48INSERT INTO assets_backup SELECT UUID,Name,Description,Type,Local,Temporary,Data FROM assets;
49DROP TABLE assets;
50CREATE TABLE assets(
51 UUID NOT NULL PRIMARY KEY,
52 Name,
53 Description,
54 Type,
55 Local,
56 Temporary,
57 asset_flags INTEGER NOT NULL DEFAULT 0,
58 CreatorID varchar(36) default '',
59 Data);
60
61INSERT INTO assets(UUID,Name,Description,Type,Local,Temporary,Data)
62SELECT UUID,Name,Description,Type,Local,Temporary,Data FROM assets_backup;
63DROP TABLE assets_backup;
64
65COMMIT;
66