Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Martin Mareš
Postal Owl
Commits
2cc77b94
Commit
2cc77b94
authored
Sep 28, 2021
by
Martin Mareš
Browse files
DB: Identifiers of courses are scoped to semester
Closes
#34
.
parent
0b6968b4
Changes
1
Hide whitespace changes
Inline
Side-by-side
db.ddl
View file @
2cc77b94
...
...
@@ -27,11 +27,12 @@ CREATE TABLE owl_semesters (
CREATE TABLE owl_courses (
cid serial PRIMARY KEY,
semid int NOT NULL REFERENCES owl_semesters(semid) ON DELETE CASCADE,
ident varchar(255)
UNIQUE
NOT NULL,
ident varchar(255) NOT NULL,
name varchar(255) NOT NULL,
enroll_token varchar(255) UNIQUE NOT NULL,
student_grading boolean NOT NULL DEFAULT FALSE,
anon_grading boolean NOT NULL DEFAULT FALSE
anon_grading boolean NOT NULL DEFAULT FALSE,
UNIQUE(semid, cid)
);
CREATE TABLE owl_enroll (
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment