Skip to content

Latest commit

 

History

History
69 lines (54 loc) · 1010 Bytes

database-design.md

File metadata and controls

69 lines (54 loc) · 1010 Bytes

database design

INFO:

  • KEYSPACE: drogon_scylladb_crud_basic

NOTE:

each highlighted section (e.g. `account`)
will represent the table name in current KEYSPACE under ## tables


tables

[V] account

create table if not exists {KEYSPACE}.{TABLE_NAME}
(
    id                  uuid,
    email               text,
    -- could be password_salt text,
    -- could be password_input text,
    created_timestamp   text,

    primary key (id)
);
/*
note:
- id:
    - assume unique
- email:
    - assume unique
*/

[X] stash

create table if not exists {KEYSPACE}.{TABLE_NAME}
(
    id                  uuid,
    id_account          uuid,
    stash_name          text,
    stash_items         list<text>,
    created_timestamp   text,

    primary key (id)
);
/*
note:
- id_account:
    - related id from account table to lookup
*/


end of database design