~azzar1/unity/add-show-desktop-key

« back to all changes in this revision

Viewing changes to www/php/phpBB3/install/schemas/sqlite_schema.sql

  • Committer: dcoles
  • Date: 2008-02-29 02:11:58 UTC
  • Revision ID: svn-v3-trunk0:2b9c9e99-6f39-0410-b283-7f802c844ae2:trunk:624
forum: Removed the subsilver2 style and phpBB installer
Modified prosilver theme to be more IVLE integrated
Added db dumps for setup

setup.py: Added config.php generator code

doc/setup/install_proc.txt: New setup/install details

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
#
2
 
# $Id: sqlite_schema.sql,v 1.105 2007/12/05 15:18:21 acydburn Exp $
3
 
#
4
 
 
5
 
BEGIN TRANSACTION;
6
 
 
7
 
# Table: 'phpbb_attachments'
8
 
CREATE TABLE phpbb_attachments (
9
 
        attach_id INTEGER PRIMARY KEY NOT NULL ,
10
 
        post_msg_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
11
 
        topic_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
12
 
        in_message INTEGER UNSIGNED NOT NULL DEFAULT '0',
13
 
        poster_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
14
 
        is_orphan INTEGER UNSIGNED NOT NULL DEFAULT '1',
15
 
        physical_filename varchar(255) NOT NULL DEFAULT '',
16
 
        real_filename varchar(255) NOT NULL DEFAULT '',
17
 
        download_count INTEGER UNSIGNED NOT NULL DEFAULT '0',
18
 
        attach_comment text(65535) NOT NULL DEFAULT '',
19
 
        extension varchar(100) NOT NULL DEFAULT '',
20
 
        mimetype varchar(100) NOT NULL DEFAULT '',
21
 
        filesize INTEGER UNSIGNED NOT NULL DEFAULT '0',
22
 
        filetime INTEGER UNSIGNED NOT NULL DEFAULT '0',
23
 
        thumbnail INTEGER UNSIGNED NOT NULL DEFAULT '0'
24
 
);
25
 
 
26
 
CREATE INDEX phpbb_attachments_filetime ON phpbb_attachments (filetime);
27
 
CREATE INDEX phpbb_attachments_post_msg_id ON phpbb_attachments (post_msg_id);
28
 
CREATE INDEX phpbb_attachments_topic_id ON phpbb_attachments (topic_id);
29
 
CREATE INDEX phpbb_attachments_poster_id ON phpbb_attachments (poster_id);
30
 
CREATE INDEX phpbb_attachments_is_orphan ON phpbb_attachments (is_orphan);
31
 
 
32
 
# Table: 'phpbb_acl_groups'
33
 
CREATE TABLE phpbb_acl_groups (
34
 
        group_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
35
 
        forum_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
36
 
        auth_option_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
37
 
        auth_role_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
38
 
        auth_setting tinyint(2) NOT NULL DEFAULT '0'
39
 
);
40
 
 
41
 
CREATE INDEX phpbb_acl_groups_group_id ON phpbb_acl_groups (group_id);
42
 
CREATE INDEX phpbb_acl_groups_auth_opt_id ON phpbb_acl_groups (auth_option_id);
43
 
CREATE INDEX phpbb_acl_groups_auth_role_id ON phpbb_acl_groups (auth_role_id);
44
 
 
45
 
# Table: 'phpbb_acl_options'
46
 
CREATE TABLE phpbb_acl_options (
47
 
        auth_option_id INTEGER PRIMARY KEY NOT NULL ,
48
 
        auth_option varchar(50) NOT NULL DEFAULT '',
49
 
        is_global INTEGER UNSIGNED NOT NULL DEFAULT '0',
50
 
        is_local INTEGER UNSIGNED NOT NULL DEFAULT '0',
51
 
        founder_only INTEGER UNSIGNED NOT NULL DEFAULT '0'
52
 
);
53
 
 
54
 
CREATE INDEX phpbb_acl_options_auth_option ON phpbb_acl_options (auth_option);
55
 
 
56
 
# Table: 'phpbb_acl_roles'
57
 
CREATE TABLE phpbb_acl_roles (
58
 
        role_id INTEGER PRIMARY KEY NOT NULL ,
59
 
        role_name varchar(255) NOT NULL DEFAULT '',
60
 
        role_description text(65535) NOT NULL DEFAULT '',
61
 
        role_type varchar(10) NOT NULL DEFAULT '',
62
 
        role_order INTEGER UNSIGNED NOT NULL DEFAULT '0'
63
 
);
64
 
 
65
 
CREATE INDEX phpbb_acl_roles_role_type ON phpbb_acl_roles (role_type);
66
 
CREATE INDEX phpbb_acl_roles_role_order ON phpbb_acl_roles (role_order);
67
 
 
68
 
# Table: 'phpbb_acl_roles_data'
69
 
CREATE TABLE phpbb_acl_roles_data (
70
 
        role_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
71
 
        auth_option_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
72
 
        auth_setting tinyint(2) NOT NULL DEFAULT '0',
73
 
        PRIMARY KEY (role_id, auth_option_id)
74
 
);
75
 
 
76
 
CREATE INDEX phpbb_acl_roles_data_ath_op_id ON phpbb_acl_roles_data (auth_option_id);
77
 
 
78
 
# Table: 'phpbb_acl_users'
79
 
CREATE TABLE phpbb_acl_users (
80
 
        user_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
81
 
        forum_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
82
 
        auth_option_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
83
 
        auth_role_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
84
 
        auth_setting tinyint(2) NOT NULL DEFAULT '0'
85
 
);
86
 
 
87
 
CREATE INDEX phpbb_acl_users_user_id ON phpbb_acl_users (user_id);
88
 
CREATE INDEX phpbb_acl_users_auth_option_id ON phpbb_acl_users (auth_option_id);
89
 
CREATE INDEX phpbb_acl_users_auth_role_id ON phpbb_acl_users (auth_role_id);
90
 
 
91
 
# Table: 'phpbb_banlist'
92
 
CREATE TABLE phpbb_banlist (
93
 
        ban_id INTEGER PRIMARY KEY NOT NULL ,
94
 
        ban_userid INTEGER UNSIGNED NOT NULL DEFAULT '0',
95
 
        ban_ip varchar(40) NOT NULL DEFAULT '',
96
 
        ban_email varchar(100) NOT NULL DEFAULT '',
97
 
        ban_start INTEGER UNSIGNED NOT NULL DEFAULT '0',
98
 
        ban_end INTEGER UNSIGNED NOT NULL DEFAULT '0',
99
 
        ban_exclude INTEGER UNSIGNED NOT NULL DEFAULT '0',
100
 
        ban_reason varchar(255) NOT NULL DEFAULT '',
101
 
        ban_give_reason varchar(255) NOT NULL DEFAULT ''
102
 
);
103
 
 
104
 
CREATE INDEX phpbb_banlist_ban_end ON phpbb_banlist (ban_end);
105
 
CREATE INDEX phpbb_banlist_ban_user ON phpbb_banlist (ban_userid, ban_exclude);
106
 
CREATE INDEX phpbb_banlist_ban_email ON phpbb_banlist (ban_email, ban_exclude);
107
 
CREATE INDEX phpbb_banlist_ban_ip ON phpbb_banlist (ban_ip, ban_exclude);
108
 
 
109
 
# Table: 'phpbb_bbcodes'
110
 
CREATE TABLE phpbb_bbcodes (
111
 
        bbcode_id tinyint(3) NOT NULL DEFAULT '0',
112
 
        bbcode_tag varchar(16) NOT NULL DEFAULT '',
113
 
        bbcode_helpline varchar(255) NOT NULL DEFAULT '',
114
 
        display_on_posting INTEGER UNSIGNED NOT NULL DEFAULT '0',
115
 
        bbcode_match text(65535) NOT NULL DEFAULT '',
116
 
        bbcode_tpl mediumtext(16777215) NOT NULL DEFAULT '',
117
 
        first_pass_match mediumtext(16777215) NOT NULL DEFAULT '',
118
 
        first_pass_replace mediumtext(16777215) NOT NULL DEFAULT '',
119
 
        second_pass_match mediumtext(16777215) NOT NULL DEFAULT '',
120
 
        second_pass_replace mediumtext(16777215) NOT NULL DEFAULT '',
121
 
        PRIMARY KEY (bbcode_id)
122
 
);
123
 
 
124
 
CREATE INDEX phpbb_bbcodes_display_on_post ON phpbb_bbcodes (display_on_posting);
125
 
 
126
 
# Table: 'phpbb_bookmarks'
127
 
CREATE TABLE phpbb_bookmarks (
128
 
        topic_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
129
 
        user_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
130
 
        PRIMARY KEY (topic_id, user_id)
131
 
);
132
 
 
133
 
 
134
 
# Table: 'phpbb_bots'
135
 
CREATE TABLE phpbb_bots (
136
 
        bot_id INTEGER PRIMARY KEY NOT NULL ,
137
 
        bot_active INTEGER UNSIGNED NOT NULL DEFAULT '1',
138
 
        bot_name text(65535) NOT NULL DEFAULT '',
139
 
        user_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
140
 
        bot_agent varchar(255) NOT NULL DEFAULT '',
141
 
        bot_ip varchar(255) NOT NULL DEFAULT ''
142
 
);
143
 
 
144
 
CREATE INDEX phpbb_bots_bot_active ON phpbb_bots (bot_active);
145
 
 
146
 
# Table: 'phpbb_config'
147
 
CREATE TABLE phpbb_config (
148
 
        config_name varchar(255) NOT NULL DEFAULT '',
149
 
        config_value varchar(255) NOT NULL DEFAULT '',
150
 
        is_dynamic INTEGER UNSIGNED NOT NULL DEFAULT '0',
151
 
        PRIMARY KEY (config_name)
152
 
);
153
 
 
154
 
CREATE INDEX phpbb_config_is_dynamic ON phpbb_config (is_dynamic);
155
 
 
156
 
# Table: 'phpbb_confirm'
157
 
CREATE TABLE phpbb_confirm (
158
 
        confirm_id char(32) NOT NULL DEFAULT '',
159
 
        session_id char(32) NOT NULL DEFAULT '',
160
 
        confirm_type tinyint(3) NOT NULL DEFAULT '0',
161
 
        code varchar(8) NOT NULL DEFAULT '',
162
 
        seed INTEGER UNSIGNED NOT NULL DEFAULT '0',
163
 
        PRIMARY KEY (session_id, confirm_id)
164
 
);
165
 
 
166
 
CREATE INDEX phpbb_confirm_confirm_type ON phpbb_confirm (confirm_type);
167
 
 
168
 
# Table: 'phpbb_disallow'
169
 
CREATE TABLE phpbb_disallow (
170
 
        disallow_id INTEGER PRIMARY KEY NOT NULL ,
171
 
        disallow_username varchar(255) NOT NULL DEFAULT ''
172
 
);
173
 
 
174
 
 
175
 
# Table: 'phpbb_drafts'
176
 
CREATE TABLE phpbb_drafts (
177
 
        draft_id INTEGER PRIMARY KEY NOT NULL ,
178
 
        user_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
179
 
        topic_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
180
 
        forum_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
181
 
        save_time INTEGER UNSIGNED NOT NULL DEFAULT '0',
182
 
        draft_subject text(65535) NOT NULL DEFAULT '',
183
 
        draft_message mediumtext(16777215) NOT NULL DEFAULT ''
184
 
);
185
 
 
186
 
CREATE INDEX phpbb_drafts_save_time ON phpbb_drafts (save_time);
187
 
 
188
 
# Table: 'phpbb_extensions'
189
 
CREATE TABLE phpbb_extensions (
190
 
        extension_id INTEGER PRIMARY KEY NOT NULL ,
191
 
        group_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
192
 
        extension varchar(100) NOT NULL DEFAULT ''
193
 
);
194
 
 
195
 
 
196
 
# Table: 'phpbb_extension_groups'
197
 
CREATE TABLE phpbb_extension_groups (
198
 
        group_id INTEGER PRIMARY KEY NOT NULL ,
199
 
        group_name varchar(255) NOT NULL DEFAULT '',
200
 
        cat_id tinyint(2) NOT NULL DEFAULT '0',
201
 
        allow_group INTEGER UNSIGNED NOT NULL DEFAULT '0',
202
 
        download_mode INTEGER UNSIGNED NOT NULL DEFAULT '1',
203
 
        upload_icon varchar(255) NOT NULL DEFAULT '',
204
 
        max_filesize INTEGER UNSIGNED NOT NULL DEFAULT '0',
205
 
        allowed_forums text(65535) NOT NULL DEFAULT '',
206
 
        allow_in_pm INTEGER UNSIGNED NOT NULL DEFAULT '0'
207
 
);
208
 
 
209
 
 
210
 
# Table: 'phpbb_forums'
211
 
CREATE TABLE phpbb_forums (
212
 
        forum_id INTEGER PRIMARY KEY NOT NULL ,
213
 
        parent_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
214
 
        left_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
215
 
        right_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
216
 
        forum_parents mediumtext(16777215) NOT NULL DEFAULT '',
217
 
        forum_name text(65535) NOT NULL DEFAULT '',
218
 
        forum_desc text(65535) NOT NULL DEFAULT '',
219
 
        forum_desc_bitfield varchar(255) NOT NULL DEFAULT '',
220
 
        forum_desc_options INTEGER UNSIGNED NOT NULL DEFAULT '7',
221
 
        forum_desc_uid varchar(8) NOT NULL DEFAULT '',
222
 
        forum_link varchar(255) NOT NULL DEFAULT '',
223
 
        forum_password varchar(40) NOT NULL DEFAULT '',
224
 
        forum_style INTEGER UNSIGNED NOT NULL DEFAULT '0',
225
 
        forum_image varchar(255) NOT NULL DEFAULT '',
226
 
        forum_rules text(65535) NOT NULL DEFAULT '',
227
 
        forum_rules_link varchar(255) NOT NULL DEFAULT '',
228
 
        forum_rules_bitfield varchar(255) NOT NULL DEFAULT '',
229
 
        forum_rules_options INTEGER UNSIGNED NOT NULL DEFAULT '7',
230
 
        forum_rules_uid varchar(8) NOT NULL DEFAULT '',
231
 
        forum_topics_per_page tinyint(4) NOT NULL DEFAULT '0',
232
 
        forum_type tinyint(4) NOT NULL DEFAULT '0',
233
 
        forum_status tinyint(4) NOT NULL DEFAULT '0',
234
 
        forum_posts INTEGER UNSIGNED NOT NULL DEFAULT '0',
235
 
        forum_topics INTEGER UNSIGNED NOT NULL DEFAULT '0',
236
 
        forum_topics_real INTEGER UNSIGNED NOT NULL DEFAULT '0',
237
 
        forum_last_post_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
238
 
        forum_last_poster_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
239
 
        forum_last_post_subject text(65535) NOT NULL DEFAULT '',
240
 
        forum_last_post_time INTEGER UNSIGNED NOT NULL DEFAULT '0',
241
 
        forum_last_poster_name varchar(255) NOT NULL DEFAULT '',
242
 
        forum_last_poster_colour varchar(6) NOT NULL DEFAULT '',
243
 
        forum_flags tinyint(4) NOT NULL DEFAULT '32',
244
 
        display_on_index INTEGER UNSIGNED NOT NULL DEFAULT '1',
245
 
        enable_indexing INTEGER UNSIGNED NOT NULL DEFAULT '1',
246
 
        enable_icons INTEGER UNSIGNED NOT NULL DEFAULT '1',
247
 
        enable_prune INTEGER UNSIGNED NOT NULL DEFAULT '0',
248
 
        prune_next INTEGER UNSIGNED NOT NULL DEFAULT '0',
249
 
        prune_days INTEGER UNSIGNED NOT NULL DEFAULT '0',
250
 
        prune_viewed INTEGER UNSIGNED NOT NULL DEFAULT '0',
251
 
        prune_freq INTEGER UNSIGNED NOT NULL DEFAULT '0'
252
 
);
253
 
 
254
 
CREATE INDEX phpbb_forums_left_right_id ON phpbb_forums (left_id, right_id);
255
 
CREATE INDEX phpbb_forums_forum_lastpost_id ON phpbb_forums (forum_last_post_id);
256
 
 
257
 
# Table: 'phpbb_forums_access'
258
 
CREATE TABLE phpbb_forums_access (
259
 
        forum_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
260
 
        user_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
261
 
        session_id char(32) NOT NULL DEFAULT '',
262
 
        PRIMARY KEY (forum_id, user_id, session_id)
263
 
);
264
 
 
265
 
 
266
 
# Table: 'phpbb_forums_track'
267
 
CREATE TABLE phpbb_forums_track (
268
 
        user_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
269
 
        forum_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
270
 
        mark_time INTEGER UNSIGNED NOT NULL DEFAULT '0',
271
 
        PRIMARY KEY (user_id, forum_id)
272
 
);
273
 
 
274
 
 
275
 
# Table: 'phpbb_forums_watch'
276
 
CREATE TABLE phpbb_forums_watch (
277
 
        forum_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
278
 
        user_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
279
 
        notify_status INTEGER UNSIGNED NOT NULL DEFAULT '0'
280
 
);
281
 
 
282
 
CREATE INDEX phpbb_forums_watch_forum_id ON phpbb_forums_watch (forum_id);
283
 
CREATE INDEX phpbb_forums_watch_user_id ON phpbb_forums_watch (user_id);
284
 
CREATE INDEX phpbb_forums_watch_notify_stat ON phpbb_forums_watch (notify_status);
285
 
 
286
 
# Table: 'phpbb_groups'
287
 
CREATE TABLE phpbb_groups (
288
 
        group_id INTEGER PRIMARY KEY NOT NULL ,
289
 
        group_type tinyint(4) NOT NULL DEFAULT '1',
290
 
        group_founder_manage INTEGER UNSIGNED NOT NULL DEFAULT '0',
291
 
        group_name varchar(255) NOT NULL DEFAULT '',
292
 
        group_desc text(65535) NOT NULL DEFAULT '',
293
 
        group_desc_bitfield varchar(255) NOT NULL DEFAULT '',
294
 
        group_desc_options INTEGER UNSIGNED NOT NULL DEFAULT '7',
295
 
        group_desc_uid varchar(8) NOT NULL DEFAULT '',
296
 
        group_display INTEGER UNSIGNED NOT NULL DEFAULT '0',
297
 
        group_avatar varchar(255) NOT NULL DEFAULT '',
298
 
        group_avatar_type tinyint(2) NOT NULL DEFAULT '0',
299
 
        group_avatar_width INTEGER UNSIGNED NOT NULL DEFAULT '0',
300
 
        group_avatar_height INTEGER UNSIGNED NOT NULL DEFAULT '0',
301
 
        group_rank INTEGER UNSIGNED NOT NULL DEFAULT '0',
302
 
        group_colour varchar(6) NOT NULL DEFAULT '',
303
 
        group_sig_chars INTEGER UNSIGNED NOT NULL DEFAULT '0',
304
 
        group_receive_pm INTEGER UNSIGNED NOT NULL DEFAULT '0',
305
 
        group_message_limit INTEGER UNSIGNED NOT NULL DEFAULT '0',
306
 
        group_legend INTEGER UNSIGNED NOT NULL DEFAULT '1'
307
 
);
308
 
 
309
 
CREATE INDEX phpbb_groups_group_legend ON phpbb_groups (group_legend);
310
 
 
311
 
# Table: 'phpbb_icons'
312
 
CREATE TABLE phpbb_icons (
313
 
        icons_id INTEGER PRIMARY KEY NOT NULL ,
314
 
        icons_url varchar(255) NOT NULL DEFAULT '',
315
 
        icons_width tinyint(4) NOT NULL DEFAULT '0',
316
 
        icons_height tinyint(4) NOT NULL DEFAULT '0',
317
 
        icons_order INTEGER UNSIGNED NOT NULL DEFAULT '0',
318
 
        display_on_posting INTEGER UNSIGNED NOT NULL DEFAULT '1'
319
 
);
320
 
 
321
 
CREATE INDEX phpbb_icons_display_on_posting ON phpbb_icons (display_on_posting);
322
 
 
323
 
# Table: 'phpbb_lang'
324
 
CREATE TABLE phpbb_lang (
325
 
        lang_id INTEGER PRIMARY KEY NOT NULL ,
326
 
        lang_iso varchar(30) NOT NULL DEFAULT '',
327
 
        lang_dir varchar(30) NOT NULL DEFAULT '',
328
 
        lang_english_name varchar(100) NOT NULL DEFAULT '',
329
 
        lang_local_name varchar(255) NOT NULL DEFAULT '',
330
 
        lang_author varchar(255) NOT NULL DEFAULT ''
331
 
);
332
 
 
333
 
CREATE INDEX phpbb_lang_lang_iso ON phpbb_lang (lang_iso);
334
 
 
335
 
# Table: 'phpbb_log'
336
 
CREATE TABLE phpbb_log (
337
 
        log_id INTEGER PRIMARY KEY NOT NULL ,
338
 
        log_type tinyint(4) NOT NULL DEFAULT '0',
339
 
        user_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
340
 
        forum_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
341
 
        topic_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
342
 
        reportee_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
343
 
        log_ip varchar(40) NOT NULL DEFAULT '',
344
 
        log_time INTEGER UNSIGNED NOT NULL DEFAULT '0',
345
 
        log_operation text(65535) NOT NULL DEFAULT '',
346
 
        log_data mediumtext(16777215) NOT NULL DEFAULT ''
347
 
);
348
 
 
349
 
CREATE INDEX phpbb_log_log_type ON phpbb_log (log_type);
350
 
CREATE INDEX phpbb_log_forum_id ON phpbb_log (forum_id);
351
 
CREATE INDEX phpbb_log_topic_id ON phpbb_log (topic_id);
352
 
CREATE INDEX phpbb_log_reportee_id ON phpbb_log (reportee_id);
353
 
CREATE INDEX phpbb_log_user_id ON phpbb_log (user_id);
354
 
 
355
 
# Table: 'phpbb_moderator_cache'
356
 
CREATE TABLE phpbb_moderator_cache (
357
 
        forum_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
358
 
        user_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
359
 
        username varchar(255) NOT NULL DEFAULT '',
360
 
        group_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
361
 
        group_name varchar(255) NOT NULL DEFAULT '',
362
 
        display_on_index INTEGER UNSIGNED NOT NULL DEFAULT '1'
363
 
);
364
 
 
365
 
CREATE INDEX phpbb_moderator_cache_disp_idx ON phpbb_moderator_cache (display_on_index);
366
 
CREATE INDEX phpbb_moderator_cache_forum_id ON phpbb_moderator_cache (forum_id);
367
 
 
368
 
# Table: 'phpbb_modules'
369
 
CREATE TABLE phpbb_modules (
370
 
        module_id INTEGER PRIMARY KEY NOT NULL ,
371
 
        module_enabled INTEGER UNSIGNED NOT NULL DEFAULT '1',
372
 
        module_display INTEGER UNSIGNED NOT NULL DEFAULT '1',
373
 
        module_basename varchar(255) NOT NULL DEFAULT '',
374
 
        module_class varchar(10) NOT NULL DEFAULT '',
375
 
        parent_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
376
 
        left_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
377
 
        right_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
378
 
        module_langname varchar(255) NOT NULL DEFAULT '',
379
 
        module_mode varchar(255) NOT NULL DEFAULT '',
380
 
        module_auth varchar(255) NOT NULL DEFAULT ''
381
 
);
382
 
 
383
 
CREATE INDEX phpbb_modules_left_right_id ON phpbb_modules (left_id, right_id);
384
 
CREATE INDEX phpbb_modules_module_enabled ON phpbb_modules (module_enabled);
385
 
CREATE INDEX phpbb_modules_class_left_id ON phpbb_modules (module_class, left_id);
386
 
 
387
 
# Table: 'phpbb_poll_options'
388
 
CREATE TABLE phpbb_poll_options (
389
 
        poll_option_id tinyint(4) NOT NULL DEFAULT '0',
390
 
        topic_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
391
 
        poll_option_text text(65535) NOT NULL DEFAULT '',
392
 
        poll_option_total INTEGER UNSIGNED NOT NULL DEFAULT '0'
393
 
);
394
 
 
395
 
CREATE INDEX phpbb_poll_options_poll_opt_id ON phpbb_poll_options (poll_option_id);
396
 
CREATE INDEX phpbb_poll_options_topic_id ON phpbb_poll_options (topic_id);
397
 
 
398
 
# Table: 'phpbb_poll_votes'
399
 
CREATE TABLE phpbb_poll_votes (
400
 
        topic_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
401
 
        poll_option_id tinyint(4) NOT NULL DEFAULT '0',
402
 
        vote_user_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
403
 
        vote_user_ip varchar(40) NOT NULL DEFAULT ''
404
 
);
405
 
 
406
 
CREATE INDEX phpbb_poll_votes_topic_id ON phpbb_poll_votes (topic_id);
407
 
CREATE INDEX phpbb_poll_votes_vote_user_id ON phpbb_poll_votes (vote_user_id);
408
 
CREATE INDEX phpbb_poll_votes_vote_user_ip ON phpbb_poll_votes (vote_user_ip);
409
 
 
410
 
# Table: 'phpbb_posts'
411
 
CREATE TABLE phpbb_posts (
412
 
        post_id INTEGER PRIMARY KEY NOT NULL ,
413
 
        topic_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
414
 
        forum_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
415
 
        poster_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
416
 
        icon_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
417
 
        poster_ip varchar(40) NOT NULL DEFAULT '',
418
 
        post_time INTEGER UNSIGNED NOT NULL DEFAULT '0',
419
 
        post_approved INTEGER UNSIGNED NOT NULL DEFAULT '1',
420
 
        post_reported INTEGER UNSIGNED NOT NULL DEFAULT '0',
421
 
        enable_bbcode INTEGER UNSIGNED NOT NULL DEFAULT '1',
422
 
        enable_smilies INTEGER UNSIGNED NOT NULL DEFAULT '1',
423
 
        enable_magic_url INTEGER UNSIGNED NOT NULL DEFAULT '1',
424
 
        enable_sig INTEGER UNSIGNED NOT NULL DEFAULT '1',
425
 
        post_username varchar(255) NOT NULL DEFAULT '',
426
 
        post_subject text(65535) NOT NULL DEFAULT '',
427
 
        post_text mediumtext(16777215) NOT NULL DEFAULT '',
428
 
        post_checksum varchar(32) NOT NULL DEFAULT '',
429
 
        post_attachment INTEGER UNSIGNED NOT NULL DEFAULT '0',
430
 
        bbcode_bitfield varchar(255) NOT NULL DEFAULT '',
431
 
        bbcode_uid varchar(8) NOT NULL DEFAULT '',
432
 
        post_postcount INTEGER UNSIGNED NOT NULL DEFAULT '1',
433
 
        post_edit_time INTEGER UNSIGNED NOT NULL DEFAULT '0',
434
 
        post_edit_reason text(65535) NOT NULL DEFAULT '',
435
 
        post_edit_user INTEGER UNSIGNED NOT NULL DEFAULT '0',
436
 
        post_edit_count INTEGER UNSIGNED NOT NULL DEFAULT '0',
437
 
        post_edit_locked INTEGER UNSIGNED NOT NULL DEFAULT '0'
438
 
);
439
 
 
440
 
CREATE INDEX phpbb_posts_forum_id ON phpbb_posts (forum_id);
441
 
CREATE INDEX phpbb_posts_topic_id ON phpbb_posts (topic_id);
442
 
CREATE INDEX phpbb_posts_poster_ip ON phpbb_posts (poster_ip);
443
 
CREATE INDEX phpbb_posts_poster_id ON phpbb_posts (poster_id);
444
 
CREATE INDEX phpbb_posts_post_approved ON phpbb_posts (post_approved);
445
 
CREATE INDEX phpbb_posts_tid_post_time ON phpbb_posts (topic_id, post_time);
446
 
 
447
 
# Table: 'phpbb_privmsgs'
448
 
CREATE TABLE phpbb_privmsgs (
449
 
        msg_id INTEGER PRIMARY KEY NOT NULL ,
450
 
        root_level INTEGER UNSIGNED NOT NULL DEFAULT '0',
451
 
        author_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
452
 
        icon_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
453
 
        author_ip varchar(40) NOT NULL DEFAULT '',
454
 
        message_time INTEGER UNSIGNED NOT NULL DEFAULT '0',
455
 
        enable_bbcode INTEGER UNSIGNED NOT NULL DEFAULT '1',
456
 
        enable_smilies INTEGER UNSIGNED NOT NULL DEFAULT '1',
457
 
        enable_magic_url INTEGER UNSIGNED NOT NULL DEFAULT '1',
458
 
        enable_sig INTEGER UNSIGNED NOT NULL DEFAULT '1',
459
 
        message_subject text(65535) NOT NULL DEFAULT '',
460
 
        message_text mediumtext(16777215) NOT NULL DEFAULT '',
461
 
        message_edit_reason text(65535) NOT NULL DEFAULT '',
462
 
        message_edit_user INTEGER UNSIGNED NOT NULL DEFAULT '0',
463
 
        message_attachment INTEGER UNSIGNED NOT NULL DEFAULT '0',
464
 
        bbcode_bitfield varchar(255) NOT NULL DEFAULT '',
465
 
        bbcode_uid varchar(8) NOT NULL DEFAULT '',
466
 
        message_edit_time INTEGER UNSIGNED NOT NULL DEFAULT '0',
467
 
        message_edit_count INTEGER UNSIGNED NOT NULL DEFAULT '0',
468
 
        to_address text(65535) NOT NULL DEFAULT '',
469
 
        bcc_address text(65535) NOT NULL DEFAULT ''
470
 
);
471
 
 
472
 
CREATE INDEX phpbb_privmsgs_author_ip ON phpbb_privmsgs (author_ip);
473
 
CREATE INDEX phpbb_privmsgs_message_time ON phpbb_privmsgs (message_time);
474
 
CREATE INDEX phpbb_privmsgs_author_id ON phpbb_privmsgs (author_id);
475
 
CREATE INDEX phpbb_privmsgs_root_level ON phpbb_privmsgs (root_level);
476
 
 
477
 
# Table: 'phpbb_privmsgs_folder'
478
 
CREATE TABLE phpbb_privmsgs_folder (
479
 
        folder_id INTEGER PRIMARY KEY NOT NULL ,
480
 
        user_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
481
 
        folder_name varchar(255) NOT NULL DEFAULT '',
482
 
        pm_count INTEGER UNSIGNED NOT NULL DEFAULT '0'
483
 
);
484
 
 
485
 
CREATE INDEX phpbb_privmsgs_folder_user_id ON phpbb_privmsgs_folder (user_id);
486
 
 
487
 
# Table: 'phpbb_privmsgs_rules'
488
 
CREATE TABLE phpbb_privmsgs_rules (
489
 
        rule_id INTEGER PRIMARY KEY NOT NULL ,
490
 
        user_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
491
 
        rule_check INTEGER UNSIGNED NOT NULL DEFAULT '0',
492
 
        rule_connection INTEGER UNSIGNED NOT NULL DEFAULT '0',
493
 
        rule_string varchar(255) NOT NULL DEFAULT '',
494
 
        rule_user_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
495
 
        rule_group_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
496
 
        rule_action INTEGER UNSIGNED NOT NULL DEFAULT '0',
497
 
        rule_folder_id int(11) NOT NULL DEFAULT '0'
498
 
);
499
 
 
500
 
CREATE INDEX phpbb_privmsgs_rules_user_id ON phpbb_privmsgs_rules (user_id);
501
 
 
502
 
# Table: 'phpbb_privmsgs_to'
503
 
CREATE TABLE phpbb_privmsgs_to (
504
 
        msg_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
505
 
        user_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
506
 
        author_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
507
 
        pm_deleted INTEGER UNSIGNED NOT NULL DEFAULT '0',
508
 
        pm_new INTEGER UNSIGNED NOT NULL DEFAULT '1',
509
 
        pm_unread INTEGER UNSIGNED NOT NULL DEFAULT '1',
510
 
        pm_replied INTEGER UNSIGNED NOT NULL DEFAULT '0',
511
 
        pm_marked INTEGER UNSIGNED NOT NULL DEFAULT '0',
512
 
        pm_forwarded INTEGER UNSIGNED NOT NULL DEFAULT '0',
513
 
        folder_id int(11) NOT NULL DEFAULT '0'
514
 
);
515
 
 
516
 
CREATE INDEX phpbb_privmsgs_to_msg_id ON phpbb_privmsgs_to (msg_id);
517
 
CREATE INDEX phpbb_privmsgs_to_author_id ON phpbb_privmsgs_to (author_id);
518
 
CREATE INDEX phpbb_privmsgs_to_usr_flder_id ON phpbb_privmsgs_to (user_id, folder_id);
519
 
 
520
 
# Table: 'phpbb_profile_fields'
521
 
CREATE TABLE phpbb_profile_fields (
522
 
        field_id INTEGER PRIMARY KEY NOT NULL ,
523
 
        field_name varchar(255) NOT NULL DEFAULT '',
524
 
        field_type tinyint(4) NOT NULL DEFAULT '0',
525
 
        field_ident varchar(20) NOT NULL DEFAULT '',
526
 
        field_length varchar(20) NOT NULL DEFAULT '',
527
 
        field_minlen varchar(255) NOT NULL DEFAULT '',
528
 
        field_maxlen varchar(255) NOT NULL DEFAULT '',
529
 
        field_novalue varchar(255) NOT NULL DEFAULT '',
530
 
        field_default_value varchar(255) NOT NULL DEFAULT '',
531
 
        field_validation varchar(20) NOT NULL DEFAULT '',
532
 
        field_required INTEGER UNSIGNED NOT NULL DEFAULT '0',
533
 
        field_show_on_reg INTEGER UNSIGNED NOT NULL DEFAULT '0',
534
 
        field_hide INTEGER UNSIGNED NOT NULL DEFAULT '0',
535
 
        field_no_view INTEGER UNSIGNED NOT NULL DEFAULT '0',
536
 
        field_active INTEGER UNSIGNED NOT NULL DEFAULT '0',
537
 
        field_order INTEGER UNSIGNED NOT NULL DEFAULT '0'
538
 
);
539
 
 
540
 
CREATE INDEX phpbb_profile_fields_fld_type ON phpbb_profile_fields (field_type);
541
 
CREATE INDEX phpbb_profile_fields_fld_ordr ON phpbb_profile_fields (field_order);
542
 
 
543
 
# Table: 'phpbb_profile_fields_data'
544
 
CREATE TABLE phpbb_profile_fields_data (
545
 
        user_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
546
 
        PRIMARY KEY (user_id)
547
 
);
548
 
 
549
 
 
550
 
# Table: 'phpbb_profile_fields_lang'
551
 
CREATE TABLE phpbb_profile_fields_lang (
552
 
        field_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
553
 
        lang_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
554
 
        option_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
555
 
        field_type tinyint(4) NOT NULL DEFAULT '0',
556
 
        lang_value varchar(255) NOT NULL DEFAULT '',
557
 
        PRIMARY KEY (field_id, lang_id, option_id)
558
 
);
559
 
 
560
 
 
561
 
# Table: 'phpbb_profile_lang'
562
 
CREATE TABLE phpbb_profile_lang (
563
 
        field_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
564
 
        lang_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
565
 
        lang_name varchar(255) NOT NULL DEFAULT '',
566
 
        lang_explain text(65535) NOT NULL DEFAULT '',
567
 
        lang_default_value varchar(255) NOT NULL DEFAULT '',
568
 
        PRIMARY KEY (field_id, lang_id)
569
 
);
570
 
 
571
 
 
572
 
# Table: 'phpbb_ranks'
573
 
CREATE TABLE phpbb_ranks (
574
 
        rank_id INTEGER PRIMARY KEY NOT NULL ,
575
 
        rank_title varchar(255) NOT NULL DEFAULT '',
576
 
        rank_min INTEGER UNSIGNED NOT NULL DEFAULT '0',
577
 
        rank_special INTEGER UNSIGNED NOT NULL DEFAULT '0',
578
 
        rank_image varchar(255) NOT NULL DEFAULT ''
579
 
);
580
 
 
581
 
 
582
 
# Table: 'phpbb_reports'
583
 
CREATE TABLE phpbb_reports (
584
 
        report_id INTEGER PRIMARY KEY NOT NULL ,
585
 
        reason_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
586
 
        post_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
587
 
        user_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
588
 
        user_notify INTEGER UNSIGNED NOT NULL DEFAULT '0',
589
 
        report_closed INTEGER UNSIGNED NOT NULL DEFAULT '0',
590
 
        report_time INTEGER UNSIGNED NOT NULL DEFAULT '0',
591
 
        report_text mediumtext(16777215) NOT NULL DEFAULT ''
592
 
);
593
 
 
594
 
 
595
 
# Table: 'phpbb_reports_reasons'
596
 
CREATE TABLE phpbb_reports_reasons (
597
 
        reason_id INTEGER PRIMARY KEY NOT NULL ,
598
 
        reason_title varchar(255) NOT NULL DEFAULT '',
599
 
        reason_description mediumtext(16777215) NOT NULL DEFAULT '',
600
 
        reason_order INTEGER UNSIGNED NOT NULL DEFAULT '0'
601
 
);
602
 
 
603
 
 
604
 
# Table: 'phpbb_search_results'
605
 
CREATE TABLE phpbb_search_results (
606
 
        search_key varchar(32) NOT NULL DEFAULT '',
607
 
        search_time INTEGER UNSIGNED NOT NULL DEFAULT '0',
608
 
        search_keywords mediumtext(16777215) NOT NULL DEFAULT '',
609
 
        search_authors mediumtext(16777215) NOT NULL DEFAULT '',
610
 
        PRIMARY KEY (search_key)
611
 
);
612
 
 
613
 
 
614
 
# Table: 'phpbb_search_wordlist'
615
 
CREATE TABLE phpbb_search_wordlist (
616
 
        word_id INTEGER PRIMARY KEY NOT NULL ,
617
 
        word_text varchar(255) NOT NULL DEFAULT '',
618
 
        word_common INTEGER UNSIGNED NOT NULL DEFAULT '0',
619
 
        word_count INTEGER UNSIGNED NOT NULL DEFAULT '0'
620
 
);
621
 
 
622
 
CREATE UNIQUE INDEX phpbb_search_wordlist_wrd_txt ON phpbb_search_wordlist (word_text);
623
 
CREATE INDEX phpbb_search_wordlist_wrd_cnt ON phpbb_search_wordlist (word_count);
624
 
 
625
 
# Table: 'phpbb_search_wordmatch'
626
 
CREATE TABLE phpbb_search_wordmatch (
627
 
        post_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
628
 
        word_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
629
 
        title_match INTEGER UNSIGNED NOT NULL DEFAULT '0'
630
 
);
631
 
 
632
 
CREATE UNIQUE INDEX phpbb_search_wordmatch_unq_mtch ON phpbb_search_wordmatch (word_id, post_id, title_match);
633
 
CREATE INDEX phpbb_search_wordmatch_word_id ON phpbb_search_wordmatch (word_id);
634
 
CREATE INDEX phpbb_search_wordmatch_post_id ON phpbb_search_wordmatch (post_id);
635
 
 
636
 
# Table: 'phpbb_sessions'
637
 
CREATE TABLE phpbb_sessions (
638
 
        session_id char(32) NOT NULL DEFAULT '',
639
 
        session_user_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
640
 
        session_last_visit INTEGER UNSIGNED NOT NULL DEFAULT '0',
641
 
        session_start INTEGER UNSIGNED NOT NULL DEFAULT '0',
642
 
        session_time INTEGER UNSIGNED NOT NULL DEFAULT '0',
643
 
        session_ip varchar(40) NOT NULL DEFAULT '',
644
 
        session_browser varchar(150) NOT NULL DEFAULT '',
645
 
        session_forwarded_for varchar(255) NOT NULL DEFAULT '',
646
 
        session_page varchar(255) NOT NULL DEFAULT '',
647
 
        session_viewonline INTEGER UNSIGNED NOT NULL DEFAULT '1',
648
 
        session_autologin INTEGER UNSIGNED NOT NULL DEFAULT '0',
649
 
        session_admin INTEGER UNSIGNED NOT NULL DEFAULT '0',
650
 
        PRIMARY KEY (session_id)
651
 
);
652
 
 
653
 
CREATE INDEX phpbb_sessions_session_time ON phpbb_sessions (session_time);
654
 
CREATE INDEX phpbb_sessions_session_user_id ON phpbb_sessions (session_user_id);
655
 
 
656
 
# Table: 'phpbb_sessions_keys'
657
 
CREATE TABLE phpbb_sessions_keys (
658
 
        key_id char(32) NOT NULL DEFAULT '',
659
 
        user_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
660
 
        last_ip varchar(40) NOT NULL DEFAULT '',
661
 
        last_login INTEGER UNSIGNED NOT NULL DEFAULT '0',
662
 
        PRIMARY KEY (key_id, user_id)
663
 
);
664
 
 
665
 
CREATE INDEX phpbb_sessions_keys_last_login ON phpbb_sessions_keys (last_login);
666
 
 
667
 
# Table: 'phpbb_sitelist'
668
 
CREATE TABLE phpbb_sitelist (
669
 
        site_id INTEGER PRIMARY KEY NOT NULL ,
670
 
        site_ip varchar(40) NOT NULL DEFAULT '',
671
 
        site_hostname varchar(255) NOT NULL DEFAULT '',
672
 
        ip_exclude INTEGER UNSIGNED NOT NULL DEFAULT '0'
673
 
);
674
 
 
675
 
 
676
 
# Table: 'phpbb_smilies'
677
 
CREATE TABLE phpbb_smilies (
678
 
        smiley_id INTEGER PRIMARY KEY NOT NULL ,
679
 
        code varchar(50) NOT NULL DEFAULT '',
680
 
        emotion varchar(50) NOT NULL DEFAULT '',
681
 
        smiley_url varchar(50) NOT NULL DEFAULT '',
682
 
        smiley_width INTEGER UNSIGNED NOT NULL DEFAULT '0',
683
 
        smiley_height INTEGER UNSIGNED NOT NULL DEFAULT '0',
684
 
        smiley_order INTEGER UNSIGNED NOT NULL DEFAULT '0',
685
 
        display_on_posting INTEGER UNSIGNED NOT NULL DEFAULT '1'
686
 
);
687
 
 
688
 
CREATE INDEX phpbb_smilies_display_on_post ON phpbb_smilies (display_on_posting);
689
 
 
690
 
# Table: 'phpbb_styles'
691
 
CREATE TABLE phpbb_styles (
692
 
        style_id INTEGER PRIMARY KEY NOT NULL ,
693
 
        style_name varchar(255) NOT NULL DEFAULT '',
694
 
        style_copyright varchar(255) NOT NULL DEFAULT '',
695
 
        style_active INTEGER UNSIGNED NOT NULL DEFAULT '1',
696
 
        template_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
697
 
        theme_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
698
 
        imageset_id INTEGER UNSIGNED NOT NULL DEFAULT '0'
699
 
);
700
 
 
701
 
CREATE UNIQUE INDEX phpbb_styles_style_name ON phpbb_styles (style_name);
702
 
CREATE INDEX phpbb_styles_template_id ON phpbb_styles (template_id);
703
 
CREATE INDEX phpbb_styles_theme_id ON phpbb_styles (theme_id);
704
 
CREATE INDEX phpbb_styles_imageset_id ON phpbb_styles (imageset_id);
705
 
 
706
 
# Table: 'phpbb_styles_template'
707
 
CREATE TABLE phpbb_styles_template (
708
 
        template_id INTEGER PRIMARY KEY NOT NULL ,
709
 
        template_name varchar(255) NOT NULL DEFAULT '',
710
 
        template_copyright varchar(255) NOT NULL DEFAULT '',
711
 
        template_path varchar(100) NOT NULL DEFAULT '',
712
 
        bbcode_bitfield varchar(255) NOT NULL DEFAULT 'kNg=',
713
 
        template_storedb INTEGER UNSIGNED NOT NULL DEFAULT '0'
714
 
);
715
 
 
716
 
CREATE UNIQUE INDEX phpbb_styles_template_tmplte_nm ON phpbb_styles_template (template_name);
717
 
 
718
 
# Table: 'phpbb_styles_template_data'
719
 
CREATE TABLE phpbb_styles_template_data (
720
 
        template_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
721
 
        template_filename varchar(100) NOT NULL DEFAULT '',
722
 
        template_included text(65535) NOT NULL DEFAULT '',
723
 
        template_mtime INTEGER UNSIGNED NOT NULL DEFAULT '0',
724
 
        template_data mediumtext(16777215) NOT NULL DEFAULT ''
725
 
);
726
 
 
727
 
CREATE INDEX phpbb_styles_template_data_tid ON phpbb_styles_template_data (template_id);
728
 
CREATE INDEX phpbb_styles_template_data_tfn ON phpbb_styles_template_data (template_filename);
729
 
 
730
 
# Table: 'phpbb_styles_theme'
731
 
CREATE TABLE phpbb_styles_theme (
732
 
        theme_id INTEGER PRIMARY KEY NOT NULL ,
733
 
        theme_name varchar(255) NOT NULL DEFAULT '',
734
 
        theme_copyright varchar(255) NOT NULL DEFAULT '',
735
 
        theme_path varchar(100) NOT NULL DEFAULT '',
736
 
        theme_storedb INTEGER UNSIGNED NOT NULL DEFAULT '0',
737
 
        theme_mtime INTEGER UNSIGNED NOT NULL DEFAULT '0',
738
 
        theme_data mediumtext(16777215) NOT NULL DEFAULT ''
739
 
);
740
 
 
741
 
CREATE UNIQUE INDEX phpbb_styles_theme_theme_name ON phpbb_styles_theme (theme_name);
742
 
 
743
 
# Table: 'phpbb_styles_imageset'
744
 
CREATE TABLE phpbb_styles_imageset (
745
 
        imageset_id INTEGER PRIMARY KEY NOT NULL ,
746
 
        imageset_name varchar(255) NOT NULL DEFAULT '',
747
 
        imageset_copyright varchar(255) NOT NULL DEFAULT '',
748
 
        imageset_path varchar(100) NOT NULL DEFAULT ''
749
 
);
750
 
 
751
 
CREATE UNIQUE INDEX phpbb_styles_imageset_imgset_nm ON phpbb_styles_imageset (imageset_name);
752
 
 
753
 
# Table: 'phpbb_styles_imageset_data'
754
 
CREATE TABLE phpbb_styles_imageset_data (
755
 
        image_id INTEGER PRIMARY KEY NOT NULL ,
756
 
        image_name varchar(200) NOT NULL DEFAULT '',
757
 
        image_filename varchar(200) NOT NULL DEFAULT '',
758
 
        image_lang varchar(30) NOT NULL DEFAULT '',
759
 
        image_height INTEGER UNSIGNED NOT NULL DEFAULT '0',
760
 
        image_width INTEGER UNSIGNED NOT NULL DEFAULT '0',
761
 
        imageset_id INTEGER UNSIGNED NOT NULL DEFAULT '0'
762
 
);
763
 
 
764
 
CREATE INDEX phpbb_styles_imageset_data_i_d ON phpbb_styles_imageset_data (imageset_id);
765
 
 
766
 
# Table: 'phpbb_topics'
767
 
CREATE TABLE phpbb_topics (
768
 
        topic_id INTEGER PRIMARY KEY NOT NULL ,
769
 
        forum_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
770
 
        icon_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
771
 
        topic_attachment INTEGER UNSIGNED NOT NULL DEFAULT '0',
772
 
        topic_approved INTEGER UNSIGNED NOT NULL DEFAULT '1',
773
 
        topic_reported INTEGER UNSIGNED NOT NULL DEFAULT '0',
774
 
        topic_title text(65535) NOT NULL DEFAULT '',
775
 
        topic_poster INTEGER UNSIGNED NOT NULL DEFAULT '0',
776
 
        topic_time INTEGER UNSIGNED NOT NULL DEFAULT '0',
777
 
        topic_time_limit INTEGER UNSIGNED NOT NULL DEFAULT '0',
778
 
        topic_views INTEGER UNSIGNED NOT NULL DEFAULT '0',
779
 
        topic_replies INTEGER UNSIGNED NOT NULL DEFAULT '0',
780
 
        topic_replies_real INTEGER UNSIGNED NOT NULL DEFAULT '0',
781
 
        topic_status tinyint(3) NOT NULL DEFAULT '0',
782
 
        topic_type tinyint(3) NOT NULL DEFAULT '0',
783
 
        topic_first_post_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
784
 
        topic_first_poster_name varchar(255) NOT NULL DEFAULT '',
785
 
        topic_first_poster_colour varchar(6) NOT NULL DEFAULT '',
786
 
        topic_last_post_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
787
 
        topic_last_poster_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
788
 
        topic_last_poster_name varchar(255) NOT NULL DEFAULT '',
789
 
        topic_last_poster_colour varchar(6) NOT NULL DEFAULT '',
790
 
        topic_last_post_subject text(65535) NOT NULL DEFAULT '',
791
 
        topic_last_post_time INTEGER UNSIGNED NOT NULL DEFAULT '0',
792
 
        topic_last_view_time INTEGER UNSIGNED NOT NULL DEFAULT '0',
793
 
        topic_moved_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
794
 
        topic_bumped INTEGER UNSIGNED NOT NULL DEFAULT '0',
795
 
        topic_bumper INTEGER UNSIGNED NOT NULL DEFAULT '0',
796
 
        poll_title text(65535) NOT NULL DEFAULT '',
797
 
        poll_start INTEGER UNSIGNED NOT NULL DEFAULT '0',
798
 
        poll_length INTEGER UNSIGNED NOT NULL DEFAULT '0',
799
 
        poll_max_options tinyint(4) NOT NULL DEFAULT '1',
800
 
        poll_last_vote INTEGER UNSIGNED NOT NULL DEFAULT '0',
801
 
        poll_vote_change INTEGER UNSIGNED NOT NULL DEFAULT '0'
802
 
);
803
 
 
804
 
CREATE INDEX phpbb_topics_forum_id ON phpbb_topics (forum_id);
805
 
CREATE INDEX phpbb_topics_forum_id_type ON phpbb_topics (forum_id, topic_type);
806
 
CREATE INDEX phpbb_topics_last_post_time ON phpbb_topics (topic_last_post_time);
807
 
CREATE INDEX phpbb_topics_topic_approved ON phpbb_topics (topic_approved);
808
 
CREATE INDEX phpbb_topics_forum_appr_last ON phpbb_topics (forum_id, topic_approved, topic_last_post_id);
809
 
CREATE INDEX phpbb_topics_fid_time_moved ON phpbb_topics (forum_id, topic_last_post_time, topic_moved_id);
810
 
 
811
 
# Table: 'phpbb_topics_track'
812
 
CREATE TABLE phpbb_topics_track (
813
 
        user_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
814
 
        topic_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
815
 
        forum_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
816
 
        mark_time INTEGER UNSIGNED NOT NULL DEFAULT '0',
817
 
        PRIMARY KEY (user_id, topic_id)
818
 
);
819
 
 
820
 
CREATE INDEX phpbb_topics_track_forum_id ON phpbb_topics_track (forum_id);
821
 
 
822
 
# Table: 'phpbb_topics_posted'
823
 
CREATE TABLE phpbb_topics_posted (
824
 
        user_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
825
 
        topic_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
826
 
        topic_posted INTEGER UNSIGNED NOT NULL DEFAULT '0',
827
 
        PRIMARY KEY (user_id, topic_id)
828
 
);
829
 
 
830
 
 
831
 
# Table: 'phpbb_topics_watch'
832
 
CREATE TABLE phpbb_topics_watch (
833
 
        topic_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
834
 
        user_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
835
 
        notify_status INTEGER UNSIGNED NOT NULL DEFAULT '0'
836
 
);
837
 
 
838
 
CREATE INDEX phpbb_topics_watch_topic_id ON phpbb_topics_watch (topic_id);
839
 
CREATE INDEX phpbb_topics_watch_user_id ON phpbb_topics_watch (user_id);
840
 
CREATE INDEX phpbb_topics_watch_notify_stat ON phpbb_topics_watch (notify_status);
841
 
 
842
 
# Table: 'phpbb_user_group'
843
 
CREATE TABLE phpbb_user_group (
844
 
        group_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
845
 
        user_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
846
 
        group_leader INTEGER UNSIGNED NOT NULL DEFAULT '0',
847
 
        user_pending INTEGER UNSIGNED NOT NULL DEFAULT '1'
848
 
);
849
 
 
850
 
CREATE INDEX phpbb_user_group_group_id ON phpbb_user_group (group_id);
851
 
CREATE INDEX phpbb_user_group_user_id ON phpbb_user_group (user_id);
852
 
CREATE INDEX phpbb_user_group_group_leader ON phpbb_user_group (group_leader);
853
 
 
854
 
# Table: 'phpbb_users'
855
 
CREATE TABLE phpbb_users (
856
 
        user_id INTEGER PRIMARY KEY NOT NULL ,
857
 
        user_type tinyint(2) NOT NULL DEFAULT '0',
858
 
        group_id INTEGER UNSIGNED NOT NULL DEFAULT '3',
859
 
        user_permissions mediumtext(16777215) NOT NULL DEFAULT '',
860
 
        user_perm_from INTEGER UNSIGNED NOT NULL DEFAULT '0',
861
 
        user_ip varchar(40) NOT NULL DEFAULT '',
862
 
        user_regdate INTEGER UNSIGNED NOT NULL DEFAULT '0',
863
 
        username varchar(255) NOT NULL DEFAULT '',
864
 
        username_clean varchar(255) NOT NULL DEFAULT '',
865
 
        user_password varchar(40) NOT NULL DEFAULT '',
866
 
        user_passchg INTEGER UNSIGNED NOT NULL DEFAULT '0',
867
 
        user_pass_convert INTEGER UNSIGNED NOT NULL DEFAULT '0',
868
 
        user_email varchar(100) NOT NULL DEFAULT '',
869
 
        user_email_hash bigint(20) NOT NULL DEFAULT '0',
870
 
        user_birthday varchar(10) NOT NULL DEFAULT '',
871
 
        user_lastvisit INTEGER UNSIGNED NOT NULL DEFAULT '0',
872
 
        user_lastmark INTEGER UNSIGNED NOT NULL DEFAULT '0',
873
 
        user_lastpost_time INTEGER UNSIGNED NOT NULL DEFAULT '0',
874
 
        user_lastpage varchar(200) NOT NULL DEFAULT '',
875
 
        user_last_confirm_key varchar(10) NOT NULL DEFAULT '',
876
 
        user_last_search INTEGER UNSIGNED NOT NULL DEFAULT '0',
877
 
        user_warnings tinyint(4) NOT NULL DEFAULT '0',
878
 
        user_last_warning INTEGER UNSIGNED NOT NULL DEFAULT '0',
879
 
        user_login_attempts tinyint(4) NOT NULL DEFAULT '0',
880
 
        user_inactive_reason tinyint(2) NOT NULL DEFAULT '0',
881
 
        user_inactive_time INTEGER UNSIGNED NOT NULL DEFAULT '0',
882
 
        user_posts INTEGER UNSIGNED NOT NULL DEFAULT '0',
883
 
        user_lang varchar(30) NOT NULL DEFAULT '',
884
 
        user_timezone decimal(5,2) NOT NULL DEFAULT '0',
885
 
        user_dst INTEGER UNSIGNED NOT NULL DEFAULT '0',
886
 
        user_dateformat varchar(30) NOT NULL DEFAULT 'd M Y H:i',
887
 
        user_style INTEGER UNSIGNED NOT NULL DEFAULT '0',
888
 
        user_rank INTEGER UNSIGNED NOT NULL DEFAULT '0',
889
 
        user_colour varchar(6) NOT NULL DEFAULT '',
890
 
        user_new_privmsg int(4) NOT NULL DEFAULT '0',
891
 
        user_unread_privmsg int(4) NOT NULL DEFAULT '0',
892
 
        user_last_privmsg INTEGER UNSIGNED NOT NULL DEFAULT '0',
893
 
        user_message_rules INTEGER UNSIGNED NOT NULL DEFAULT '0',
894
 
        user_full_folder int(11) NOT NULL DEFAULT '-3',
895
 
        user_emailtime INTEGER UNSIGNED NOT NULL DEFAULT '0',
896
 
        user_topic_show_days INTEGER UNSIGNED NOT NULL DEFAULT '0',
897
 
        user_topic_sortby_type varchar(1) NOT NULL DEFAULT 't',
898
 
        user_topic_sortby_dir varchar(1) NOT NULL DEFAULT 'd',
899
 
        user_post_show_days INTEGER UNSIGNED NOT NULL DEFAULT '0',
900
 
        user_post_sortby_type varchar(1) NOT NULL DEFAULT 't',
901
 
        user_post_sortby_dir varchar(1) NOT NULL DEFAULT 'a',
902
 
        user_notify INTEGER UNSIGNED NOT NULL DEFAULT '0',
903
 
        user_notify_pm INTEGER UNSIGNED NOT NULL DEFAULT '1',
904
 
        user_notify_type tinyint(4) NOT NULL DEFAULT '0',
905
 
        user_allow_pm INTEGER UNSIGNED NOT NULL DEFAULT '1',
906
 
        user_allow_viewonline INTEGER UNSIGNED NOT NULL DEFAULT '1',
907
 
        user_allow_viewemail INTEGER UNSIGNED NOT NULL DEFAULT '1',
908
 
        user_allow_massemail INTEGER UNSIGNED NOT NULL DEFAULT '1',
909
 
        user_options INTEGER UNSIGNED NOT NULL DEFAULT '895',
910
 
        user_avatar varchar(255) NOT NULL DEFAULT '',
911
 
        user_avatar_type tinyint(2) NOT NULL DEFAULT '0',
912
 
        user_avatar_width INTEGER UNSIGNED NOT NULL DEFAULT '0',
913
 
        user_avatar_height INTEGER UNSIGNED NOT NULL DEFAULT '0',
914
 
        user_sig mediumtext(16777215) NOT NULL DEFAULT '',
915
 
        user_sig_bbcode_uid varchar(8) NOT NULL DEFAULT '',
916
 
        user_sig_bbcode_bitfield varchar(255) NOT NULL DEFAULT '',
917
 
        user_from varchar(100) NOT NULL DEFAULT '',
918
 
        user_icq varchar(15) NOT NULL DEFAULT '',
919
 
        user_aim varchar(255) NOT NULL DEFAULT '',
920
 
        user_yim varchar(255) NOT NULL DEFAULT '',
921
 
        user_msnm varchar(255) NOT NULL DEFAULT '',
922
 
        user_jabber varchar(255) NOT NULL DEFAULT '',
923
 
        user_website varchar(200) NOT NULL DEFAULT '',
924
 
        user_occ text(65535) NOT NULL DEFAULT '',
925
 
        user_interests text(65535) NOT NULL DEFAULT '',
926
 
        user_actkey varchar(32) NOT NULL DEFAULT '',
927
 
        user_newpasswd varchar(40) NOT NULL DEFAULT '',
928
 
        user_form_salt varchar(32) NOT NULL DEFAULT ''
929
 
);
930
 
 
931
 
CREATE INDEX phpbb_users_user_birthday ON phpbb_users (user_birthday);
932
 
CREATE INDEX phpbb_users_user_email_hash ON phpbb_users (user_email_hash);
933
 
CREATE INDEX phpbb_users_user_type ON phpbb_users (user_type);
934
 
CREATE UNIQUE INDEX phpbb_users_username_clean ON phpbb_users (username_clean);
935
 
 
936
 
# Table: 'phpbb_warnings'
937
 
CREATE TABLE phpbb_warnings (
938
 
        warning_id INTEGER PRIMARY KEY NOT NULL ,
939
 
        user_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
940
 
        post_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
941
 
        log_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
942
 
        warning_time INTEGER UNSIGNED NOT NULL DEFAULT '0'
943
 
);
944
 
 
945
 
 
946
 
# Table: 'phpbb_words'
947
 
CREATE TABLE phpbb_words (
948
 
        word_id INTEGER PRIMARY KEY NOT NULL ,
949
 
        word varchar(255) NOT NULL DEFAULT '',
950
 
        replacement varchar(255) NOT NULL DEFAULT ''
951
 
);
952
 
 
953
 
 
954
 
# Table: 'phpbb_zebra'
955
 
CREATE TABLE phpbb_zebra (
956
 
        user_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
957
 
        zebra_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
958
 
        friend INTEGER UNSIGNED NOT NULL DEFAULT '0',
959
 
        foe INTEGER UNSIGNED NOT NULL DEFAULT '0',
960
 
        PRIMARY KEY (user_id, zebra_id)
961
 
);
962
 
 
963
 
 
964
 
 
965
 
COMMIT;
 
 
b'\\ No newline at end of file'