]> git.mxchange.org Git - friendica.git/blob - doc/database/db_notification.md
Merge pull request #13390 from annando/channel
[friendica.git] / doc / database / db_notification.md
1 Table notification
2 ===========
3
4 notifications
5
6 Fields
7 ------
8
9 | Field         | Description                                                                    | Type               | Null | Key | Default | Extra          |
10 | ------------- | ------------------------------------------------------------------------------ | ------------------ | ---- | --- | ------- | -------------- |
11 | id            | sequential ID                                                                  | int unsigned       | NO   | PRI | NULL    | auto_increment |
12 | uid           | Owner User id                                                                  | mediumint unsigned | YES  |     | NULL    |                |
13 | vid           | Id of the verb table entry that contains the activity verbs                    | smallint unsigned  | YES  |     | NULL    |                |
14 | type          |                                                                                | smallint unsigned  | YES  |     | NULL    |                |
15 | actor-id      | Link to the contact table with uid=0 of the actor that caused the notification | int unsigned       | YES  |     | NULL    |                |
16 | target-uri-id | Item-uri id of the related post                                                | int unsigned       | YES  |     | NULL    |                |
17 | parent-uri-id | Item-uri id of the parent of the related post                                  | int unsigned       | YES  |     | NULL    |                |
18 | created       |                                                                                | datetime           | YES  |     | NULL    |                |
19 | seen          | Seen on the desktop                                                            | boolean            | YES  |     | 0       |                |
20 | dismissed     | Dismissed via the API                                                          | boolean            | YES  |     | 0       |                |
21
22 Indexes
23 ------------
24
25 | Name                                | Fields                                          |
26 | ----------------------------------- | ----------------------------------------------- |
27 | PRIMARY                             | id                                              |
28 | uid_vid_type_actor-id_target-uri-id | UNIQUE, uid, vid, type, actor-id, target-uri-id |
29 | vid                                 | vid                                             |
30 | actor-id                            | actor-id                                        |
31 | target-uri-id                       | target-uri-id                                   |
32 | parent-uri-id                       | parent-uri-id                                   |
33 | seen_uid                            | seen, uid                                       |
34 | uid_type_parent-uri-id_actor-id     | uid, type, parent-uri-id, actor-id              |
35
36 Foreign Keys
37 ------------
38
39 | Field | Target Table | Target Field |
40 |-------|--------------|--------------|
41 | uid | [user](help/database/db_user) | uid |
42 | vid | [verb](help/database/db_verb) | id |
43 | actor-id | [contact](help/database/db_contact) | id |
44 | target-uri-id | [item-uri](help/database/db_item-uri) | id |
45 | parent-uri-id | [item-uri](help/database/db_item-uri) | id |
46
47 Return to [database documentation](help/database)