Table.phpbb topics
From phpBB Development Wiki
(Redirected from Tables/phpbb topics)
description goes here
Fields
| column | type (MySQL) | content | default |
|---|---|---|---|
| topic_id | mediumint(8) unsigned | primary key | auto_increment |
| forum_id | mediumint(8) unsigned |
references phpbb_forums.forum_id | 0 |
| icon_id | mediumint(8) unsigned |
references phpbb_icons.icon_id | 0 |
| topic_attachment | tinyint(1) unsigned | 1=at least one post in this topic has attachment 0=no attachments in this topic | 0 |
| topic_approved | tinyint(1) unsigned | tbd | 1 |
| topic_reported | tinyint(1) unsigned | tbd | 0 |
| topic_title | varchar(100) | tbd | |
| topic_poster | mediumint(8) unsigned |
references phpbb_users.user_id | 0 |
| topic_time | int(11) unsigned | tbd | 0 |
| topic_time_limit | int(11) unsigned | tbd | 0 |
| topic_views | mediumint(8) unsigned | tbd | 0 |
| topic_replies | mediumint(8) unsigned | the number of approved replies to this topic | 0 |
| topic_replies_real | mediumint(8) unsigned | total replies to this topic (including posts waiting for approval) | 0 |
| topic_status | tinyint(3) | ITEM_UNLOCKED(0), ITEM_LOCKED(1) or ITEM_MOVED(2) | 0 |
| topic_type | tinyint(3) | POST_NORMAL(0), POST_STICKY(1), POST_ANNOUNCE(2) or POST_GLOBAL(3)
note that when topic_type is POST_GLOBAL (global announcement), then forum_id must be 0 | 0 |
| topic_first_post_id | mediumint(8) unsigned |
references phpbb_posts.post_id | 0 |
| topic_first_poster_name | varchar(255) | tbd | |
| topic_first_poster_colour | varchar(6) | tbd | |
| topic_last_post_id | mediumint(8) unsigned |
references phpbb_posts.post_id | 0 |
| topic_last_poster_id | mediumint(8) unsigned |
references phpbb_users.user_id | 0 |
| topic_last_poster_name | varchar(255) | tbd | |
| topic_last_poster_colour | varchar(6) | tbd | |
| topic_last_post_subject | varchar(100) | tbd | |
| topic_last_post_time | int(11) unsigned | unix timestamp | 0 |
| topic_last_view_time | int(11) unsigned | unix timestamp | 0 |
| topic_moved_id | mediumint(8) unsigned | if topic_status is ITEM_MOVED, this field contains the topic id of the real topic | 0 |
| topic_bumped | tinyint(1) unsigned | has this topic been bumped? 1 (yes), 0(no) | 0 |
| topic_bumper | mediumint(8) unsigned |
references phpbb_users.user_id | 0 |
| poll_title | varchar(100) | tbd | |
| poll_start | int(11) unsigned | unix timestamp | 0 |
| poll_length | int(11) unsigned | unix timestamp | 0 |
| poll_max_options | tinyint(4) | how many poll options can each user choose | 1 |
| poll_last_vote | int(11) unsigned | unix timestamp | 0 |
| poll_vote_change | tinyint(1) unsigned | are users allowed to change their vote(s)? 1 (yes), 0(no) | 0 |
Keys
| name | fields |
|---|---|
| PRIMARY | topic_id |
| forum_id | forum_id |
| forum_id_type | forum_id |
| topic_type | |
| last_post_time | topic_last_post_time |
| topic_approved | topic_approved |
| fid_time_moved | forum_id |
| topic_last_post_time | |
| topic_moved_id |

