diff options
| author | timb <timb@mb.local> | 2010-04-11 12:23:49 -0700 |
|---|---|---|
| committer | timb <timb@mb.local> | 2010-04-11 12:23:49 -0700 |
| commit | b489d3df189b2a87e3d8b1ba321b9a8f2a441009 (patch) | |
| tree | d3c5f21221f9e8e3cf7199ce77379840ffeb86ac /db/0-create.psql | |
| parent | e25c1aa942e11b3bcfd74d803f50796db14e47ff (diff) | |
| parent | a0ab1dd2f38437c69b51f95de10993f43aa7c8a2 (diff) | |
Merge branch 'master' of ssh://dump.fm/pichat/repo
Diffstat (limited to 'db/0-create.psql')
| -rw-r--r-- | db/0-create.psql | 13 |
1 files changed, 0 insertions, 13 deletions
diff --git a/db/0-create.psql b/db/0-create.psql index 3ab384c..e0c5443 100644 --- a/db/0-create.psql +++ b/db/0-create.psql @@ -37,19 +37,6 @@ CREATE INDEX messages_created_on_idx ON messages (created_on); CREATE INDEX messages_is_image_idx ON messages (is_image); -- Queries to support: --- 1) What are my favorite images? (By room, time, or author) --- 2) Who favorited me? (By user, image, or time) --- 3) What are the most favorited images? (By room, time, or author) -CREATE TABLE favorites ( - favorite_id SERIAL PRIMARY KEY, - src_user_id integer NOT NULL REFERENCES users, - message_id integer NOT NULL REFERENCES messages, - created_on timestamp NOT NULL DEFAULT now() -); -CREATE INDEX src_user_id_idx ON favorites (src_user_id); -CREATE INDEX favorites_created_on_idx on favorites (created_on); - --- Queries to support: -- 1) What messages are tagged x? (ordered by time, popularity) -- 2) What did I tag x? -- 3) Which of my things are tagged x? |
