Create tables for runs and measurements

This commit is contained in:
Joscha 2023-08-09 16:27:25 +02:00
parent e5de9ccb97
commit 65d23f0994

View file

@ -0,0 +1,18 @@
CREATE TABLE runs (
id TEXT NOT NULL PRIMARY KEY,
hash TEXT NOT NULL,
FOREIGN KEY (hash) REFERENCES commits (hash) ON DELETE CASCADE
) STRICT;
CREATE TABLE measurements (
id TEXT NOT NULL,
name TEXT NOT NULL,
value REAL NOT NULL,
stddev REAL,
unit TEXT,
direction INT,
PRIMARY KEY (id, name),
FOREIGN KEY (id) REFERENCES runs (id) ON DELETE CASCADE
) STRICT;