diff options
author | Matthias Andreas Benkard <code@mail.matthias.benkard.de> | 2011-03-02 19:15:52 +0100 |
---|---|---|
committer | Matthias Andreas Benkard <code@mail.matthias.benkard.de> | 2011-03-02 19:15:52 +0100 |
commit | fd87dbade6aee9c8c69a3a3ae65758fb71e87118 (patch) | |
tree | d04525fa140522dbcc93595ebc174ea32cacf294 | |
parent | 2f6bd466afd2463b96e2b1c8047c63054155b727 (diff) |
Database schema: Add more metadata to comments.
-rw-r--r-- | schema.sql | 23 |
1 files changed, 13 insertions, 10 deletions
@@ -65,8 +65,9 @@ CREATE TABLE article_aliases( ); CREATE TABLE comments( - id SERIAL NOT NULL, - article INTEGER NOT NULL, + id SERIAL NOT NULL, + article INTEGER NOT NULL, + global_id VARCHAR, PRIMARY KEY (id), FOREIGN KEY (article) REFERENCES articles ); @@ -106,14 +107,16 @@ CREATE TABLE article_revision_parenthood( ); CREATE TABLE comment_revisions( - id SERIAL NOT NULL, - comment INTEGER NOT NULL, - date TIMESTAMP DEFAULT now(), - content VARCHAR NOT NULL, - author INTEGER, - format VARCHAR NOT NULL, - status VARCHAR NOT NULL, - article_revision INTEGER, + id SERIAL NOT NULL, + comment INTEGER NOT NULL, + date TIMESTAMP DEFAULT now(), + content VARCHAR NOT NULL, + author INTEGER, + submitter_ip INET, + submitter_user_agent VARCHAR, + format VARCHAR NOT NULL, + status VARCHAR NOT NULL, + article_revision INTEGER, PRIMARY KEY (id), FOREIGN KEY (comment) REFERENCES comments, FOREIGN KEY (author) REFERENCES users, |