]> git.mxchange.org Git - friendica.git/blob - doc/database/db_contact-relation.md
HTML-escape notification contact names
[friendica.git] / doc / database / db_contact-relation.md
1 Table contact-relation
2 ===========
3
4 Contact relations
5
6 Fields
7 ------
8
9 | Field                 | Description                                              | Type              | Null | Key | Default             | Extra |
10 | --------------------- | -------------------------------------------------------- | ----------------- | ---- | --- | ------------------- | ----- |
11 | cid                   | contact the related contact had interacted with          | int unsigned      | NO   | PRI | 0                   |       |
12 | relation-cid          | related contact who had interacted with the contact      | int unsigned      | NO   | PRI | 0                   |       |
13 | last-interaction      | Date of the last interaction by relation-cid on cid      | datetime          | NO   |     | 0001-01-01 00:00:00 |       |
14 | follow-updated        | Date of the last update of the contact relationship      | datetime          | NO   |     | 0001-01-01 00:00:00 |       |
15 | follows               | if true, relation-cid follows cid                        | boolean           | NO   |     | 0                   |       |
16 | score                 | score for interactions of cid on relation-cid            | smallint unsigned | YES  |     | NULL                |       |
17 | relation-score        | score for interactions of relation-cid on cid            | smallint unsigned | YES  |     | NULL                |       |
18 | thread-score          | score for interactions of cid on threads of relation-cid | smallint unsigned | YES  |     | NULL                |       |
19 | relation-thread-score | score for interactions of relation-cid on threads of cid | smallint unsigned | YES  |     | NULL                |       |
20
21 Indexes
22 ------------
23
24 | Name         | Fields            |
25 | ------------ | ----------------- |
26 | PRIMARY      | cid, relation-cid |
27 | relation-cid | relation-cid      |
28
29 Foreign Keys
30 ------------
31
32 | Field | Target Table | Target Field |
33 |-------|--------------|--------------|
34 | cid | [contact](help/database/db_contact) | id |
35 | relation-cid | [contact](help/database/db_contact) | id |
36
37 Return to [database documentation](help/database)