]> git.mxchange.org Git - friendica.git/blob - doc/database/db_post-thread-user.md
Merge pull request #13729 from annando/frio-channel
[friendica.git] / doc / database / db_post-thread-user.md
1 Table post-thread-user
2 ===========
3
4 Thread related data per user
5
6 Fields
7 ------
8
9 | Field           | Description                                                                                             | Type               | Null | Key | Default             | Extra |
10 | --------------- | ------------------------------------------------------------------------------------------------------- | ------------------ | ---- | --- | ------------------- | ----- |
11 | uri-id          | Id of the item-uri table entry that contains the item uri                                               | int unsigned       | NO   | PRI | NULL                |       |
12 | conversation-id | Id of the item-uri table entry that contains the conversation uri                                       | int unsigned       | YES  |     | NULL                |       |
13 | owner-id        | Item owner                                                                                              | int unsigned       | NO   |     | 0                   |       |
14 | author-id       | Item author                                                                                             | int unsigned       | NO   |     | 0                   |       |
15 | causer-id       | Link to the contact table with uid=0 of the contact that caused the item creation                       | int unsigned       | YES  |     | NULL                |       |
16 | network         |                                                                                                         | char(4)            | NO   |     |                     |       |
17 | created         |                                                                                                         | datetime           | NO   |     | 0001-01-01 00:00:00 |       |
18 | received        |                                                                                                         | datetime           | NO   |     | 0001-01-01 00:00:00 |       |
19 | changed         | Date that something in the conversation changed, indicating clients should fetch the conversation again | datetime           | NO   |     | 0001-01-01 00:00:00 |       |
20 | commented       |                                                                                                         | datetime           | NO   |     | 0001-01-01 00:00:00 |       |
21 | uid             | Owner id which owns this copy of the item                                                               | mediumint unsigned | NO   | PRI | 0                   |       |
22 | pinned          | deprecated                                                                                              | boolean            | NO   |     | 0                   |       |
23 | starred         |                                                                                                         | boolean            | NO   |     | 0                   |       |
24 | ignored         | Ignore updates for this thread                                                                          | boolean            | NO   |     | 0                   |       |
25 | wall            | This item was posted to the wall of uid                                                                 | boolean            | NO   |     | 0                   |       |
26 | mention         |                                                                                                         | boolean            | NO   |     | 0                   |       |
27 | pubmail         |                                                                                                         | boolean            | NO   |     | 0                   |       |
28 | forum_mode      | Deprecated                                                                                              | tinyint unsigned   | NO   |     | 0                   |       |
29 | contact-id      | contact.id                                                                                              | int unsigned       | NO   |     | 0                   |       |
30 | unseen          | post has not been seen                                                                                  | boolean            | NO   |     | 1                   |       |
31 | hidden          | Marker to hide the post from the user                                                                   | boolean            | NO   |     | 0                   |       |
32 | origin          | item originated at this site                                                                            | boolean            | NO   |     | 0                   |       |
33 | psid            | ID of the permission set of this post                                                                   | int unsigned       | YES  |     | NULL                |       |
34 | post-user-id    | Id of the post-user table                                                                               | int unsigned       | YES  |     | NULL                |       |
35
36 Indexes
37 ------------
38
39 | Name                 | Fields                |
40 | -------------------- | --------------------- |
41 | PRIMARY              | uid, uri-id           |
42 | uri-id               | uri-id                |
43 | conversation-id      | conversation-id       |
44 | owner-id             | owner-id              |
45 | author-id            | author-id             |
46 | causer-id            | causer-id             |
47 | uid                  | uid                   |
48 | contact-id           | contact-id            |
49 | psid                 | psid                  |
50 | post-user-id         | post-user-id          |
51 | commented            | commented             |
52 | received             | received              |
53 | author-id_created    | author-id, created    |
54 | owner-id_created     | owner-id, created     |
55 | uid_received         | uid, received         |
56 | uid_wall_received    | uid, wall, received   |
57 | uid_commented        | uid, commented        |
58 | uid_created          | uid, created          |
59 | uid_starred          | uid, starred          |
60 | uid_mention          | uid, mention          |
61 | contact-id_commented | contact-id, commented |
62 | contact-id_received  | contact-id, received  |
63 | contact-id_created   | contact-id, created   |
64
65 Foreign Keys
66 ------------
67
68 | Field | Target Table | Target Field |
69 |-------|--------------|--------------|
70 | uri-id | [item-uri](help/database/db_item-uri) | id |
71 | conversation-id | [item-uri](help/database/db_item-uri) | id |
72 | owner-id | [contact](help/database/db_contact) | id |
73 | author-id | [contact](help/database/db_contact) | id |
74 | causer-id | [contact](help/database/db_contact) | id |
75 | uid | [user](help/database/db_user) | uid |
76 | contact-id | [contact](help/database/db_contact) | id |
77 | psid | [permissionset](help/database/db_permissionset) | id |
78 | post-user-id | [post-user](help/database/db_post-user) | id |
79
80 Return to [database documentation](help/database)