diff options
author | adam <adam@> | 2021-02-12 13:55:01 +0200 |
---|---|---|
committer | adam <adam@> | 2021-02-12 13:55:01 +0200 |
commit | e26ab014a12650b77cc323ee5c0218e68405bfa0 (patch) | |
tree | 986281d1d00da58548d5cc55d482785f57c23a5b /sql | |
parent | 3909f0306619241b46848bcab602a22103fa15ba (diff) | |
download | fileup-e26ab014a12650b77cc323ee5c0218e68405bfa0.tar.gz |
sql restructure
Diffstat (limited to 'sql')
-rw-r--r-- | sql/fileshare.sql | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sql/fileshare.sql b/sql/fileshare.sql index b0f1696..b3c9c6e 100644 --- a/sql/fileshare.sql +++ b/sql/fileshare.sql @@ -12,7 +12,6 @@ create table nodes ( is_directory boolean default false, relative_path varchar(500) not null, type varchar(20) not null default 'data', - name varchar(100) not null default 'no name', note varchar(200) not null default "", code varchar(100) not null default "error", primary key (node_id) @@ -39,10 +38,11 @@ create table node_access ( foreign key (node_id) references nodes(node_id), foreign key (user_id) references users(user_id) ); - +/*we can name a node in many different ways */ create table node_links ( directory_id int not null, node_id int not null, + name varchar(100) not null default 'no name', check (directory_id != node_id), foreign key (directory_id) references nodes(node_id), foreign key (node_id) references nodes(node_id) |