hyperlog/crates/hyperlog-server/migrations/crdb/20240201211013_initial.sql
kjuulh 699bac7159
All checks were successful
continuous-integration/drone/push Build is passing
feat: server can actually create root and sections
Signed-off-by: kjuulh <contact@kjuulh.io>
2024-05-13 22:57:20 +02:00

15 lines
299 B
SQL

-- Add migration script here
CREATE TABLE roots (
id UUID NOT NULL PRIMARY KEY,
root_name VARCHAR(255) UNIQUE NOT NULL
);
CREATE TABLE nodes (
id UUID NOT NULL PRIMARY KEY,
root_id UUID NOT NULL,
path VARCHAR NOT NULL,
item_type VARCHAR NOT NULL,
item_content JSONB
);