Advertisement
Guest User

Untitled

a guest
Sep 19th, 2019
80
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.98 KB | None | 0 0
  1. const thread_table_sql = "CREATE TABLE IF NOT EXISTS Threads (" +
  2. "thread_id TEXT PRIMARY KEY," +
  3. "author INTEGER REFERENCES Users(user_id)," +
  4. "board string REFERENCES Boards(board_id)," +
  5. "name TEXT NOT NULL," +
  6. "description TEXT NOT NULL," +
  7. "created_at TIMESTAMP NOT NULL" +
  8. ");";
  9. const post_table_sql = "CREATE TABLE IF NOT EXISTS Posts (" +
  10. "post_id TEXT PRIMARY KEY," +
  11. "author INTEGER REFERENCES Users(user_id)," +
  12. "thread TEXT REFERENCES Threads(thread_id)," +
  13. "title TEXT," +
  14. "content TEXT," +
  15. "reply_to string REFERENCES Posts(post_id)," +
  16. "created_at TIMESTAMP NOT NULL" +
  17. ");";
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement