Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
C
caosdb-mysqlbackend
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
caosdb
Software
caosdb-mysqlbackend
Commits
26c3cb0b
Verified
Commit
26c3cb0b
authored
5 years ago
by
Timm Fitschen
Browse files
Options
Downloads
Patches
Plain Diff
WIP: patch
parent
a213a3fd
Branches
Branches containing commit
No related tags found
1 merge request
!12
DRAFT: ENH: file system: core
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
patches/patch20200623-3.0.0rc2/patch.sql
+4
-3
4 additions, 3 deletions
patches/patch20200623-3.0.0rc2/patch.sql
with
4 additions
and
3 deletions
patches/patch20200623-3.0.0rc2/patch.sql
+
4
−
3
View file @
26c3cb0b
...
@@ -2,6 +2,7 @@
...
@@ -2,6 +2,7 @@
-- REMOVE SQLITE datatype
-- REMOVE SQLITE datatype
DELETE
FROM
name_data
WHERE
entity_id
=
50
;
DELETE
FROM
entities
WHERE
id
=
50
;
DELETE
FROM
entities
WHERE
id
=
50
;
ALTER
TABLE
files
ADD
UNIQUE
(
`path`
);
ALTER
TABLE
files
ADD
UNIQUE
(
`path`
);
...
@@ -15,8 +16,8 @@ ALTER TABLE files ADD COLUMN IF NOT EXISTS (
...
@@ -15,8 +16,8 @@ ALTER TABLE files ADD COLUMN IF NOT EXISTS (
ALTER
TABLE
entities
MODIFY
COLUMN
`role`
enum
(
'RECORDTYPE'
,
'RECORD'
,
'FILE'
,
'DOMAIN'
,
'PROPERTY'
,
'DATATYPE'
,
'ROLE'
,
'QUERYTEMPLATE'
,
'DIRECTORY'
)
COLLATE
utf8_unicode_ci
NOT
NULL
;
ALTER
TABLE
entities
MODIFY
COLUMN
`role`
enum
(
'RECORDTYPE'
,
'RECORD'
,
'FILE'
,
'DOMAIN'
,
'PROPERTY'
,
'DATATYPE'
,
'ROLE'
,
'QUERYTEMPLATE'
,
'DIRECTORY'
)
COLLATE
utf8_unicode_ci
NOT
NULL
;
INSERT
IGNORE
INTO
entities
(
id
,
description
,
role
,
acl
)
VALUES
(
9
,
"The directory role."
,
"ROLE"
,
0
);
INSERT
INTO
entities
(
id
,
description
,
role
,
acl
)
VALUES
(
9
,
"The directory role."
,
"ROLE"
,
0
);
INSERT
IGNORE
INTO
name_data
(
domain_id
,
entity_id
,
property_id
,
value
,
status
,
pidx
)
VALUES
(
0
,
9
,
20
,
"DIRECTORY"
,
"FIX"
,
0
);
INSERT
INTO
name_data
(
domain_id
,
entity_id
,
property_id
,
value
,
status
,
pidx
)
VALUES
(
0
,
9
,
20
,
"DIRECTORY"
,
"FIX"
,
0
);
UPDATE
files
SET
storageId
=
path
;
UPDATE
files
SET
storageId
=
path
;
...
@@ -55,7 +56,7 @@ BEGIN
...
@@ -55,7 +56,7 @@ BEGIN
SET
dir_exists
=
FALSE
;
SET
dir_exists
=
FALSE
;
ITERATE
loop2
;
ITERATE
loop2
;
END
IF
;
END
IF
;
INSERT
INTO
entities
(
name
,
description
,
role
,
acl
)
VALUES
(
NULL
,
NULL
,
"DIRECTORY"
,
0
);
INSERT
INTO
entities
(
description
,
role
,
acl
)
VALUES
(
NULL
,
NULL
,
"DIRECTORY"
,
0
);
SET
dir_id
=
LAST_INSERT_ID
();
SET
dir_id
=
LAST_INSERT_ID
();
INSERT
INTO
files
(
file_id
,
path
,
size
,
hash
,
checked_timestamp
,
mimetype
,
fileStorage
,
storageId
)
VALUES
(
dir_id
,
LEFT
(
dir_path
,
CHAR_LENGTH
(
dir_path
)
-
1
),
0
,
NULL
,
0
,
"inode/directory"
,
"DEFAULT"
,
LEFT
(
dir_path
,
CHAR_LENGTH
(
dir_path
)
-
1
));
INSERT
INTO
files
(
file_id
,
path
,
size
,
hash
,
checked_timestamp
,
mimetype
,
fileStorage
,
storageId
)
VALUES
(
dir_id
,
LEFT
(
dir_path
,
CHAR_LENGTH
(
dir_path
)
-
1
),
0
,
NULL
,
0
,
"inode/directory"
,
"DEFAULT"
,
LEFT
(
dir_path
,
CHAR_LENGTH
(
dir_path
)
-
1
));
END
LOOP
;
END
LOOP
;
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment