diff options
| author | Georgios Andreadis <g.andreadis@student.tudelft.nl> | 2018-03-24 11:55:45 +0100 |
|---|---|---|
| committer | Fabian Mastenbroek <mail.fabianm@gmail.com> | 2018-08-14 19:15:20 +0200 |
| commit | aa97e067caae9cbe25fc9140fc3e625933615fb9 (patch) | |
| tree | a2f4ae7a60073d6023c8d233a6d01309e069f666 /database | |
| parent | 1ccc68defdb1f67f39dc836ee6659a89135c038c (diff) | |
feat: Add job id to DB schema
Diffstat (limited to 'database')
| -rw-r--r-- | database/schema.sql | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/database/schema.sql b/database/schema.sql index 3b751c30..b9460701 100644 --- a/database/schema.sql +++ b/database/schema.sql @@ -253,6 +253,7 @@ CREATE TABLE task_metrics ( id INTEGER PRIMARY KEY NOT NULL AUTO_INCREMENT, experiment_id INTEGER NOT NULL, task_id INTEGER NOT NULL, + job_id INTEGER NOT NULL, waiting INTEGER NOT NULL CHECK (waiting >= 0), execution INTEGER NOT NULL CHECK (execution >= 0), turnaround INTEGER NOT NULL CHECK (turnaround >= 0), @@ -262,6 +263,9 @@ CREATE TABLE task_metrics ( ON UPDATE CASCADE, FOREIGN KEY (task_id) REFERENCES tasks (id) ON DELETE CASCADE + ON UPDATE CASCADE, + FOREIGN KEY (job_id) REFERENCES jobs (id) + ON DELETE CASCADE ON UPDATE CASCADE ); |
