diff options
author | Julien Dessaux | 2023-09-02 02:16:42 +0200 |
---|---|---|
committer | Julien Dessaux | 2023-09-02 02:16:42 +0200 |
commit | e03bb9061103cb11cd3c55a32fa688bde8c01e3b (patch) | |
tree | b8848f1ef2d61c9c1e836c822542a2f45d54d043 /nodejs/database/000_init.sql | |
parent | [javascript] began reworking token handling to match what is done with the ha... (diff) | |
download | spacetraders-e03bb9061103cb11cd3c55a32fa688bde8c01e3b.tar.gz spacetraders-e03bb9061103cb11cd3c55a32fa688bde8c01e3b.tar.bz2 spacetraders-e03bb9061103cb11cd3c55a32fa688bde8c01e3b.zip |
[javascript] added contracts and agent database management
Diffstat (limited to 'nodejs/database/000_init.sql')
-rw-r--r-- | nodejs/database/000_init.sql | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/nodejs/database/000_init.sql b/nodejs/database/000_init.sql index c06d2d3..9c06622 100644 --- a/nodejs/database/000_init.sql +++ b/nodejs/database/000_init.sql @@ -5,3 +5,12 @@ CREATE TABLE tokens ( id INTEGER PRIMARY KEY, data TEXT NOT NULL ); +CREATE TABLE agents ( + id INTEGER PRIMARY KEY, + data TEXT NOT NULL +); +CREATE TABLE contracts ( + id INTEGER PRIMARY KEY, + data TEXT NOT NULL +); +CREATE UNIQUE INDEX contracts_data_id ON contracts (json_extract(data, '$.id')); |