]> git.mxchange.org Git - friendica.git/blob - doc/database/db_notification.md
Updated documentation
[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          |                                                                                | tinyint 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          |                                                                                | boolean            | YES  |     | 0       |                |
20
21 Indexes
22 ------------
23
24 | Name | Fields |
25 |------|--------|
26 | PRIMARY | id |
27 | uid_vid_type_actor-id_target-uri-id | UNIQUE, uid, vid, type, actor-id, target-uri-id |
28 | vid | vid |
29 | actor-id | actor-id |
30 | target-uri-id | target-uri-id |
31 | parent-uri-id | parent-uri-id |
32 | seen_uid | seen, uid |
33
34 Foreign Keys
35 ------------
36
37 | Field | Target Table | Target Field |
38 |-------|--------------|--------------|
39 | uid | [user](help/database/db_user) | uid |
40 | vid | [verb](help/database/db_verb) | id |
41 | actor-id | [contact](help/database/db_contact) | id |
42 | target-uri-id | [item-uri](help/database/db_item-uri) | id |
43 | parent-uri-id | [item-uri](help/database/db_item-uri) | id |
44
45 Return to [database documentation](help/database)