Chris
8bc91a14f5
All checks were successful
Build and push / Pulling repo on server (push) Successful in 3s
40 lines
753 B
SQL
40 lines
753 B
SQL
BEGIN TRANSACTION;
|
|
CREATE TABLE IF NOT EXISTS "events" (
|
|
"ID" INTEGER UNIQUE,
|
|
"name" TEXT,
|
|
"date" TEXT,
|
|
"organizer" TEXT,
|
|
PRIMARY KEY("ID")
|
|
);
|
|
CREATE TABLE IF NOT EXISTS "runs" (
|
|
"id" INTEGER UNIQUE,
|
|
"event" INTEGER,
|
|
"name" TEXT,
|
|
"lk" TEXT,
|
|
"gk" TEXT,
|
|
FOREIGN KEY("event") REFERENCES "events"("ID"),
|
|
PRIMARY KEY("id")
|
|
);
|
|
CREATE TABLE IF NOT EXISTS "results" (
|
|
"id" INTEGER,
|
|
"event" INTEGER,
|
|
"run" INTEGER,
|
|
"rang" TEXT,
|
|
"stnr" INTEGER,
|
|
"teilnehmer" TEXT,
|
|
"hund" TEXT,
|
|
"verein" TEXT,
|
|
"f" INTEGER,
|
|
"vw" INTEGER,
|
|
"zf" INTEGER,
|
|
"zeit" REAL,
|
|
"gf" REAL,
|
|
"msek" REAL,
|
|
"bew" TEXT,
|
|
"punkte" TEXT,
|
|
PRIMARY KEY("id" AUTOINCREMENT),
|
|
FOREIGN KEY("run") REFERENCES "runs"("id"),
|
|
FOREIGN KEY("event") REFERENCES "events"("ID")
|
|
);
|
|
COMMIT;
|