[ Index ] |
PHP Cross Reference of Unnamed Project |
[Summary view] [Print] [Text view]
1 /* 2 * DO NOT EDIT THIS FILE, IT IS GENERATED 3 * 4 * To change the contents of this file, edit 5 * phpBB/develop/create_schema_files.php and 6 * run it. 7 */ 8 9 /* 10 This first section is optional, however its probably the best method 11 of running phpBB on Oracle. If you already have a tablespace and user created 12 for phpBB you can leave this section commented out! 13 14 The first set of statements create a phpBB tablespace and a phpBB user, 15 make sure you change the password of the phpBB user before you run this script!! 16 */ 17 18 /* 19 CREATE TABLESPACE "PHPBB" 20 LOGGING 21 DATAFILE 'E:\ORACLE\ORADATA\LOCAL\PHPBB.ora' 22 SIZE 10M 23 AUTOEXTEND ON NEXT 10M 24 MAXSIZE 100M; 25 26 CREATE USER "PHPBB" 27 PROFILE "DEFAULT" 28 IDENTIFIED BY "phpbb_password" 29 DEFAULT TABLESPACE "PHPBB" 30 QUOTA UNLIMITED ON "PHPBB" 31 ACCOUNT UNLOCK; 32 33 GRANT ANALYZE ANY TO "PHPBB"; 34 GRANT CREATE SEQUENCE TO "PHPBB"; 35 GRANT CREATE SESSION TO "PHPBB"; 36 GRANT CREATE TABLE TO "PHPBB"; 37 GRANT CREATE TRIGGER TO "PHPBB"; 38 GRANT CREATE VIEW TO "PHPBB"; 39 GRANT "CONNECT" TO "PHPBB"; 40 41 COMMIT; 42 DISCONNECT; 43 44 CONNECT phpbb/phpbb_password; 45 */ 46 /* 47 Table: 'phpbb_attachments' 48 */ 49 CREATE TABLE phpbb_attachments ( 50 attach_id number(8) NOT NULL, 51 post_msg_id number(8) DEFAULT '0' NOT NULL, 52 topic_id number(8) DEFAULT '0' NOT NULL, 53 in_message number(1) DEFAULT '0' NOT NULL, 54 poster_id number(8) DEFAULT '0' NOT NULL, 55 is_orphan number(1) DEFAULT '1' NOT NULL, 56 physical_filename varchar2(255) DEFAULT '' , 57 real_filename varchar2(255) DEFAULT '' , 58 download_count number(8) DEFAULT '0' NOT NULL, 59 attach_comment clob DEFAULT '' , 60 extension varchar2(100) DEFAULT '' , 61 mimetype varchar2(100) DEFAULT '' , 62 filesize number(20) DEFAULT '0' NOT NULL, 63 filetime number(11) DEFAULT '0' NOT NULL, 64 thumbnail number(1) DEFAULT '0' NOT NULL, 65 CONSTRAINT pk_phpbb_attachments PRIMARY KEY (attach_id) 66 ) 67 / 68 69 CREATE INDEX phpbb_attachments_filetime ON phpbb_attachments (filetime) 70 / 71 CREATE INDEX phpbb_attachments_post_msg_id ON phpbb_attachments (post_msg_id) 72 / 73 CREATE INDEX phpbb_attachments_topic_id ON phpbb_attachments (topic_id) 74 / 75 CREATE INDEX phpbb_attachments_poster_id ON phpbb_attachments (poster_id) 76 / 77 CREATE INDEX phpbb_attachments_is_orphan ON phpbb_attachments (is_orphan) 78 / 79 80 CREATE SEQUENCE phpbb_attachments_seq 81 / 82 83 CREATE OR REPLACE TRIGGER t_phpbb_attachments 84 BEFORE INSERT ON phpbb_attachments 85 FOR EACH ROW WHEN ( 86 new.attach_id IS NULL OR new.attach_id = 0 87 ) 88 BEGIN 89 SELECT phpbb_attachments_seq.nextval 90 INTO :new.attach_id 91 FROM dual; 92 END; 93 / 94 95 96 /* 97 Table: 'phpbb_acl_groups' 98 */ 99 CREATE TABLE phpbb_acl_groups ( 100 group_id number(8) DEFAULT '0' NOT NULL, 101 forum_id number(8) DEFAULT '0' NOT NULL, 102 auth_option_id number(8) DEFAULT '0' NOT NULL, 103 auth_role_id number(8) DEFAULT '0' NOT NULL, 104 auth_setting number(2) DEFAULT '0' NOT NULL 105 ) 106 / 107 108 CREATE INDEX phpbb_acl_groups_group_id ON phpbb_acl_groups (group_id) 109 / 110 CREATE INDEX phpbb_acl_groups_auth_opt_id ON phpbb_acl_groups (auth_option_id) 111 / 112 CREATE INDEX phpbb_acl_groups_auth_role_id ON phpbb_acl_groups (auth_role_id) 113 / 114 115 /* 116 Table: 'phpbb_acl_options' 117 */ 118 CREATE TABLE phpbb_acl_options ( 119 auth_option_id number(8) NOT NULL, 120 auth_option varchar2(50) DEFAULT '' , 121 is_global number(1) DEFAULT '0' NOT NULL, 122 is_local number(1) DEFAULT '0' NOT NULL, 123 founder_only number(1) DEFAULT '0' NOT NULL, 124 CONSTRAINT pk_phpbb_acl_options PRIMARY KEY (auth_option_id), 125 CONSTRAINT u_phpbb_auth_option UNIQUE (auth_option) 126 ) 127 / 128 129 130 CREATE SEQUENCE phpbb_acl_options_seq 131 / 132 133 CREATE OR REPLACE TRIGGER t_phpbb_acl_options 134 BEFORE INSERT ON phpbb_acl_options 135 FOR EACH ROW WHEN ( 136 new.auth_option_id IS NULL OR new.auth_option_id = 0 137 ) 138 BEGIN 139 SELECT phpbb_acl_options_seq.nextval 140 INTO :new.auth_option_id 141 FROM dual; 142 END; 143 / 144 145 146 /* 147 Table: 'phpbb_acl_roles' 148 */ 149 CREATE TABLE phpbb_acl_roles ( 150 role_id number(8) NOT NULL, 151 role_name varchar2(765) DEFAULT '' , 152 role_description clob DEFAULT '' , 153 role_type varchar2(10) DEFAULT '' , 154 role_order number(4) DEFAULT '0' NOT NULL, 155 CONSTRAINT pk_phpbb_acl_roles PRIMARY KEY (role_id) 156 ) 157 / 158 159 CREATE INDEX phpbb_acl_roles_role_type ON phpbb_acl_roles (role_type) 160 / 161 CREATE INDEX phpbb_acl_roles_role_order ON phpbb_acl_roles (role_order) 162 / 163 164 CREATE SEQUENCE phpbb_acl_roles_seq 165 / 166 167 CREATE OR REPLACE TRIGGER t_phpbb_acl_roles 168 BEFORE INSERT ON phpbb_acl_roles 169 FOR EACH ROW WHEN ( 170 new.role_id IS NULL OR new.role_id = 0 171 ) 172 BEGIN 173 SELECT phpbb_acl_roles_seq.nextval 174 INTO :new.role_id 175 FROM dual; 176 END; 177 / 178 179 180 /* 181 Table: 'phpbb_acl_roles_data' 182 */ 183 CREATE TABLE phpbb_acl_roles_data ( 184 role_id number(8) DEFAULT '0' NOT NULL, 185 auth_option_id number(8) DEFAULT '0' NOT NULL, 186 auth_setting number(2) DEFAULT '0' NOT NULL, 187 CONSTRAINT pk_phpbb_acl_roles_data PRIMARY KEY (role_id, auth_option_id) 188 ) 189 / 190 191 CREATE INDEX phpbb_acl_roles_data_ath_op_id ON phpbb_acl_roles_data (auth_option_id) 192 / 193 194 /* 195 Table: 'phpbb_acl_users' 196 */ 197 CREATE TABLE phpbb_acl_users ( 198 user_id number(8) DEFAULT '0' NOT NULL, 199 forum_id number(8) DEFAULT '0' NOT NULL, 200 auth_option_id number(8) DEFAULT '0' NOT NULL, 201 auth_role_id number(8) DEFAULT '0' NOT NULL, 202 auth_setting number(2) DEFAULT '0' NOT NULL 203 ) 204 / 205 206 CREATE INDEX phpbb_acl_users_user_id ON phpbb_acl_users (user_id) 207 / 208 CREATE INDEX phpbb_acl_users_auth_option_id ON phpbb_acl_users (auth_option_id) 209 / 210 CREATE INDEX phpbb_acl_users_auth_role_id ON phpbb_acl_users (auth_role_id) 211 / 212 213 /* 214 Table: 'phpbb_banlist' 215 */ 216 CREATE TABLE phpbb_banlist ( 217 ban_id number(8) NOT NULL, 218 ban_userid number(8) DEFAULT '0' NOT NULL, 219 ban_ip varchar2(40) DEFAULT '' , 220 ban_email varchar2(300) DEFAULT '' , 221 ban_start number(11) DEFAULT '0' NOT NULL, 222 ban_end number(11) DEFAULT '0' NOT NULL, 223 ban_exclude number(1) DEFAULT '0' NOT NULL, 224 ban_reason varchar2(765) DEFAULT '' , 225 ban_give_reason varchar2(765) DEFAULT '' , 226 CONSTRAINT pk_phpbb_banlist PRIMARY KEY (ban_id) 227 ) 228 / 229 230 CREATE INDEX phpbb_banlist_ban_end ON phpbb_banlist (ban_end) 231 / 232 CREATE INDEX phpbb_banlist_ban_user ON phpbb_banlist (ban_userid, ban_exclude) 233 / 234 CREATE INDEX phpbb_banlist_ban_email ON phpbb_banlist (ban_email, ban_exclude) 235 / 236 CREATE INDEX phpbb_banlist_ban_ip ON phpbb_banlist (ban_ip, ban_exclude) 237 / 238 239 CREATE SEQUENCE phpbb_banlist_seq 240 / 241 242 CREATE OR REPLACE TRIGGER t_phpbb_banlist 243 BEFORE INSERT ON phpbb_banlist 244 FOR EACH ROW WHEN ( 245 new.ban_id IS NULL OR new.ban_id = 0 246 ) 247 BEGIN 248 SELECT phpbb_banlist_seq.nextval 249 INTO :new.ban_id 250 FROM dual; 251 END; 252 / 253 254 255 /* 256 Table: 'phpbb_bbcodes' 257 */ 258 CREATE TABLE phpbb_bbcodes ( 259 bbcode_id number(4) DEFAULT '0' NOT NULL, 260 bbcode_tag varchar2(16) DEFAULT '' , 261 bbcode_helpline varchar2(765) DEFAULT '' , 262 display_on_posting number(1) DEFAULT '0' NOT NULL, 263 bbcode_match clob DEFAULT '' , 264 bbcode_tpl clob DEFAULT '' , 265 first_pass_match clob DEFAULT '' , 266 first_pass_replace clob DEFAULT '' , 267 second_pass_match clob DEFAULT '' , 268 second_pass_replace clob DEFAULT '' , 269 CONSTRAINT pk_phpbb_bbcodes PRIMARY KEY (bbcode_id) 270 ) 271 / 272 273 CREATE INDEX phpbb_bbcodes_display_on_post ON phpbb_bbcodes (display_on_posting) 274 / 275 276 /* 277 Table: 'phpbb_bookmarks' 278 */ 279 CREATE TABLE phpbb_bookmarks ( 280 topic_id number(8) DEFAULT '0' NOT NULL, 281 user_id number(8) DEFAULT '0' NOT NULL, 282 CONSTRAINT pk_phpbb_bookmarks PRIMARY KEY (topic_id, user_id) 283 ) 284 / 285 286 287 /* 288 Table: 'phpbb_bots' 289 */ 290 CREATE TABLE phpbb_bots ( 291 bot_id number(8) NOT NULL, 292 bot_active number(1) DEFAULT '1' NOT NULL, 293 bot_name varchar2(765) DEFAULT '' , 294 user_id number(8) DEFAULT '0' NOT NULL, 295 bot_agent varchar2(255) DEFAULT '' , 296 bot_ip varchar2(255) DEFAULT '' , 297 CONSTRAINT pk_phpbb_bots PRIMARY KEY (bot_id) 298 ) 299 / 300 301 CREATE INDEX phpbb_bots_bot_active ON phpbb_bots (bot_active) 302 / 303 304 CREATE SEQUENCE phpbb_bots_seq 305 / 306 307 CREATE OR REPLACE TRIGGER t_phpbb_bots 308 BEFORE INSERT ON phpbb_bots 309 FOR EACH ROW WHEN ( 310 new.bot_id IS NULL OR new.bot_id = 0 311 ) 312 BEGIN 313 SELECT phpbb_bots_seq.nextval 314 INTO :new.bot_id 315 FROM dual; 316 END; 317 / 318 319 320 /* 321 Table: 'phpbb_config' 322 */ 323 CREATE TABLE phpbb_config ( 324 config_name varchar2(255) DEFAULT '' , 325 config_value varchar2(765) DEFAULT '' , 326 is_dynamic number(1) DEFAULT '0' NOT NULL, 327 CONSTRAINT pk_phpbb_config PRIMARY KEY (config_name) 328 ) 329 / 330 331 CREATE INDEX phpbb_config_is_dynamic ON phpbb_config (is_dynamic) 332 / 333 334 /* 335 Table: 'phpbb_confirm' 336 */ 337 CREATE TABLE phpbb_confirm ( 338 confirm_id char(32) DEFAULT '' , 339 session_id char(32) DEFAULT '' , 340 confirm_type number(3) DEFAULT '0' NOT NULL, 341 code varchar2(8) DEFAULT '' , 342 seed number(10) DEFAULT '0' NOT NULL, 343 attempts number(8) DEFAULT '0' NOT NULL, 344 CONSTRAINT pk_phpbb_confirm PRIMARY KEY (session_id, confirm_id) 345 ) 346 / 347 348 CREATE INDEX phpbb_confirm_confirm_type ON phpbb_confirm (confirm_type) 349 / 350 351 /* 352 Table: 'phpbb_disallow' 353 */ 354 CREATE TABLE phpbb_disallow ( 355 disallow_id number(8) NOT NULL, 356 disallow_username varchar2(765) DEFAULT '' , 357 CONSTRAINT pk_phpbb_disallow PRIMARY KEY (disallow_id) 358 ) 359 / 360 361 362 CREATE SEQUENCE phpbb_disallow_seq 363 / 364 365 CREATE OR REPLACE TRIGGER t_phpbb_disallow 366 BEFORE INSERT ON phpbb_disallow 367 FOR EACH ROW WHEN ( 368 new.disallow_id IS NULL OR new.disallow_id = 0 369 ) 370 BEGIN 371 SELECT phpbb_disallow_seq.nextval 372 INTO :new.disallow_id 373 FROM dual; 374 END; 375 / 376 377 378 /* 379 Table: 'phpbb_drafts' 380 */ 381 CREATE TABLE phpbb_drafts ( 382 draft_id number(8) NOT NULL, 383 user_id number(8) DEFAULT '0' NOT NULL, 384 topic_id number(8) DEFAULT '0' NOT NULL, 385 forum_id number(8) DEFAULT '0' NOT NULL, 386 save_time number(11) DEFAULT '0' NOT NULL, 387 draft_subject varchar2(765) DEFAULT '' , 388 draft_message clob DEFAULT '' , 389 CONSTRAINT pk_phpbb_drafts PRIMARY KEY (draft_id) 390 ) 391 / 392 393 CREATE INDEX phpbb_drafts_save_time ON phpbb_drafts (save_time) 394 / 395 396 CREATE SEQUENCE phpbb_drafts_seq 397 / 398 399 CREATE OR REPLACE TRIGGER t_phpbb_drafts 400 BEFORE INSERT ON phpbb_drafts 401 FOR EACH ROW WHEN ( 402 new.draft_id IS NULL OR new.draft_id = 0 403 ) 404 BEGIN 405 SELECT phpbb_drafts_seq.nextval 406 INTO :new.draft_id 407 FROM dual; 408 END; 409 / 410 411 412 /* 413 Table: 'phpbb_extensions' 414 */ 415 CREATE TABLE phpbb_extensions ( 416 extension_id number(8) NOT NULL, 417 group_id number(8) DEFAULT '0' NOT NULL, 418 extension varchar2(100) DEFAULT '' , 419 CONSTRAINT pk_phpbb_extensions PRIMARY KEY (extension_id) 420 ) 421 / 422 423 424 CREATE SEQUENCE phpbb_extensions_seq 425 / 426 427 CREATE OR REPLACE TRIGGER t_phpbb_extensions 428 BEFORE INSERT ON phpbb_extensions 429 FOR EACH ROW WHEN ( 430 new.extension_id IS NULL OR new.extension_id = 0 431 ) 432 BEGIN 433 SELECT phpbb_extensions_seq.nextval 434 INTO :new.extension_id 435 FROM dual; 436 END; 437 / 438 439 440 /* 441 Table: 'phpbb_extension_groups' 442 */ 443 CREATE TABLE phpbb_extension_groups ( 444 group_id number(8) NOT NULL, 445 group_name varchar2(765) DEFAULT '' , 446 cat_id number(2) DEFAULT '0' NOT NULL, 447 allow_group number(1) DEFAULT '0' NOT NULL, 448 download_mode number(1) DEFAULT '1' NOT NULL, 449 upload_icon varchar2(255) DEFAULT '' , 450 max_filesize number(20) DEFAULT '0' NOT NULL, 451 allowed_forums clob DEFAULT '' , 452 allow_in_pm number(1) DEFAULT '0' NOT NULL, 453 CONSTRAINT pk_phpbb_extension_groups PRIMARY KEY (group_id) 454 ) 455 / 456 457 458 CREATE SEQUENCE phpbb_extension_groups_seq 459 / 460 461 CREATE OR REPLACE TRIGGER t_phpbb_extension_groups 462 BEFORE INSERT ON phpbb_extension_groups 463 FOR EACH ROW WHEN ( 464 new.group_id IS NULL OR new.group_id = 0 465 ) 466 BEGIN 467 SELECT phpbb_extension_groups_seq.nextval 468 INTO :new.group_id 469 FROM dual; 470 END; 471 / 472 473 474 /* 475 Table: 'phpbb_forums' 476 */ 477 CREATE TABLE phpbb_forums ( 478 forum_id number(8) NOT NULL, 479 parent_id number(8) DEFAULT '0' NOT NULL, 480 left_id number(8) DEFAULT '0' NOT NULL, 481 right_id number(8) DEFAULT '0' NOT NULL, 482 forum_parents clob DEFAULT '' , 483 forum_name varchar2(765) DEFAULT '' , 484 forum_desc clob DEFAULT '' , 485 forum_desc_bitfield varchar2(255) DEFAULT '' , 486 forum_desc_options number(11) DEFAULT '7' NOT NULL, 487 forum_desc_uid varchar2(8) DEFAULT '' , 488 forum_link varchar2(765) DEFAULT '' , 489 forum_password varchar2(120) DEFAULT '' , 490 forum_style number(8) DEFAULT '0' NOT NULL, 491 forum_image varchar2(255) DEFAULT '' , 492 forum_rules clob DEFAULT '' , 493 forum_rules_link varchar2(765) DEFAULT '' , 494 forum_rules_bitfield varchar2(255) DEFAULT '' , 495 forum_rules_options number(11) DEFAULT '7' NOT NULL, 496 forum_rules_uid varchar2(8) DEFAULT '' , 497 forum_topics_per_page number(4) DEFAULT '0' NOT NULL, 498 forum_type number(4) DEFAULT '0' NOT NULL, 499 forum_status number(4) DEFAULT '0' NOT NULL, 500 forum_posts number(8) DEFAULT '0' NOT NULL, 501 forum_topics number(8) DEFAULT '0' NOT NULL, 502 forum_topics_real number(8) DEFAULT '0' NOT NULL, 503 forum_last_post_id number(8) DEFAULT '0' NOT NULL, 504 forum_last_poster_id number(8) DEFAULT '0' NOT NULL, 505 forum_last_post_subject varchar2(765) DEFAULT '' , 506 forum_last_post_time number(11) DEFAULT '0' NOT NULL, 507 forum_last_poster_name varchar2(765) DEFAULT '' , 508 forum_last_poster_colour varchar2(6) DEFAULT '' , 509 forum_flags number(4) DEFAULT '32' NOT NULL, 510 forum_options number(20) DEFAULT '0' NOT NULL, 511 display_subforum_list number(1) DEFAULT '1' NOT NULL, 512 display_on_index number(1) DEFAULT '1' NOT NULL, 513 enable_indexing number(1) DEFAULT '1' NOT NULL, 514 enable_icons number(1) DEFAULT '1' NOT NULL, 515 enable_prune number(1) DEFAULT '0' NOT NULL, 516 prune_next number(11) DEFAULT '0' NOT NULL, 517 prune_days number(8) DEFAULT '0' NOT NULL, 518 prune_viewed number(8) DEFAULT '0' NOT NULL, 519 prune_freq number(8) DEFAULT '0' NOT NULL, 520 CONSTRAINT pk_phpbb_forums PRIMARY KEY (forum_id) 521 ) 522 / 523 524 CREATE INDEX phpbb_forums_left_right_id ON phpbb_forums (left_id, right_id) 525 / 526 CREATE INDEX phpbb_forums_forum_lastpost_id ON phpbb_forums (forum_last_post_id) 527 / 528 529 CREATE SEQUENCE phpbb_forums_seq 530 / 531 532 CREATE OR REPLACE TRIGGER t_phpbb_forums 533 BEFORE INSERT ON phpbb_forums 534 FOR EACH ROW WHEN ( 535 new.forum_id IS NULL OR new.forum_id = 0 536 ) 537 BEGIN 538 SELECT phpbb_forums_seq.nextval 539 INTO :new.forum_id 540 FROM dual; 541 END; 542 / 543 544 545 /* 546 Table: 'phpbb_forums_access' 547 */ 548 CREATE TABLE phpbb_forums_access ( 549 forum_id number(8) DEFAULT '0' NOT NULL, 550 user_id number(8) DEFAULT '0' NOT NULL, 551 session_id char(32) DEFAULT '' , 552 CONSTRAINT pk_phpbb_forums_access PRIMARY KEY (forum_id, user_id, session_id) 553 ) 554 / 555 556 557 /* 558 Table: 'phpbb_forums_track' 559 */ 560 CREATE TABLE phpbb_forums_track ( 561 user_id number(8) DEFAULT '0' NOT NULL, 562 forum_id number(8) DEFAULT '0' NOT NULL, 563 mark_time number(11) DEFAULT '0' NOT NULL, 564 CONSTRAINT pk_phpbb_forums_track PRIMARY KEY (user_id, forum_id) 565 ) 566 / 567 568 569 /* 570 Table: 'phpbb_forums_watch' 571 */ 572 CREATE TABLE phpbb_forums_watch ( 573 forum_id number(8) DEFAULT '0' NOT NULL, 574 user_id number(8) DEFAULT '0' NOT NULL, 575 notify_status number(1) DEFAULT '0' NOT NULL 576 ) 577 / 578 579 CREATE INDEX phpbb_forums_watch_forum_id ON phpbb_forums_watch (forum_id) 580 / 581 CREATE INDEX phpbb_forums_watch_user_id ON phpbb_forums_watch (user_id) 582 / 583 CREATE INDEX phpbb_forums_watch_notify_stat ON phpbb_forums_watch (notify_status) 584 / 585 586 /* 587 Table: 'phpbb_groups' 588 */ 589 CREATE TABLE phpbb_groups ( 590 group_id number(8) NOT NULL, 591 group_type number(4) DEFAULT '1' NOT NULL, 592 group_founder_manage number(1) DEFAULT '0' NOT NULL, 593 group_skip_auth number(1) DEFAULT '0' NOT NULL, 594 group_name varchar2(255) DEFAULT '' , 595 group_desc clob DEFAULT '' , 596 group_desc_bitfield varchar2(255) DEFAULT '' , 597 group_desc_options number(11) DEFAULT '7' NOT NULL, 598 group_desc_uid varchar2(8) DEFAULT '' , 599 group_display number(1) DEFAULT '0' NOT NULL, 600 group_avatar varchar2(255) DEFAULT '' , 601 group_avatar_type number(2) DEFAULT '0' NOT NULL, 602 group_avatar_width number(4) DEFAULT '0' NOT NULL, 603 group_avatar_height number(4) DEFAULT '0' NOT NULL, 604 group_rank number(8) DEFAULT '0' NOT NULL, 605 group_colour varchar2(6) DEFAULT '' , 606 group_sig_chars number(8) DEFAULT '0' NOT NULL, 607 group_receive_pm number(1) DEFAULT '0' NOT NULL, 608 group_message_limit number(8) DEFAULT '0' NOT NULL, 609 group_max_recipients number(8) DEFAULT '0' NOT NULL, 610 group_legend number(1) DEFAULT '1' NOT NULL, 611 CONSTRAINT pk_phpbb_groups PRIMARY KEY (group_id) 612 ) 613 / 614 615 CREATE INDEX phpbb_groups_group_legend_name ON phpbb_groups (group_legend, group_name) 616 / 617 618 CREATE SEQUENCE phpbb_groups_seq 619 / 620 621 CREATE OR REPLACE TRIGGER t_phpbb_groups 622 BEFORE INSERT ON phpbb_groups 623 FOR EACH ROW WHEN ( 624 new.group_id IS NULL OR new.group_id = 0 625 ) 626 BEGIN 627 SELECT phpbb_groups_seq.nextval 628 INTO :new.group_id 629 FROM dual; 630 END; 631 / 632 633 634 /* 635 Table: 'phpbb_icons' 636 */ 637 CREATE TABLE phpbb_icons ( 638 icons_id number(8) NOT NULL, 639 icons_url varchar2(255) DEFAULT '' , 640 icons_width number(4) DEFAULT '0' NOT NULL, 641 icons_height number(4) DEFAULT '0' NOT NULL, 642 icons_order number(8) DEFAULT '0' NOT NULL, 643 display_on_posting number(1) DEFAULT '1' NOT NULL, 644 CONSTRAINT pk_phpbb_icons PRIMARY KEY (icons_id) 645 ) 646 / 647 648 CREATE INDEX phpbb_icons_display_on_posting ON phpbb_icons (display_on_posting) 649 / 650 651 CREATE SEQUENCE phpbb_icons_seq 652 / 653 654 CREATE OR REPLACE TRIGGER t_phpbb_icons 655 BEFORE INSERT ON phpbb_icons 656 FOR EACH ROW WHEN ( 657 new.icons_id IS NULL OR new.icons_id = 0 658 ) 659 BEGIN 660 SELECT phpbb_icons_seq.nextval 661 INTO :new.icons_id 662 FROM dual; 663 END; 664 / 665 666 667 /* 668 Table: 'phpbb_lang' 669 */ 670 CREATE TABLE phpbb_lang ( 671 lang_id number(4) NOT NULL, 672 lang_iso varchar2(30) DEFAULT '' , 673 lang_dir varchar2(30) DEFAULT '' , 674 lang_english_name varchar2(300) DEFAULT '' , 675 lang_local_name varchar2(765) DEFAULT '' , 676 lang_author varchar2(765) DEFAULT '' , 677 CONSTRAINT pk_phpbb_lang PRIMARY KEY (lang_id) 678 ) 679 / 680 681 CREATE INDEX phpbb_lang_lang_iso ON phpbb_lang (lang_iso) 682 / 683 684 CREATE SEQUENCE phpbb_lang_seq 685 / 686 687 CREATE OR REPLACE TRIGGER t_phpbb_lang 688 BEFORE INSERT ON phpbb_lang 689 FOR EACH ROW WHEN ( 690 new.lang_id IS NULL OR new.lang_id = 0 691 ) 692 BEGIN 693 SELECT phpbb_lang_seq.nextval 694 INTO :new.lang_id 695 FROM dual; 696 END; 697 / 698 699 700 /* 701 Table: 'phpbb_log' 702 */ 703 CREATE TABLE phpbb_log ( 704 log_id number(8) NOT NULL, 705 log_type number(4) DEFAULT '0' NOT NULL, 706 user_id number(8) DEFAULT '0' NOT NULL, 707 forum_id number(8) DEFAULT '0' NOT NULL, 708 topic_id number(8) DEFAULT '0' NOT NULL, 709 reportee_id number(8) DEFAULT '0' NOT NULL, 710 log_ip varchar2(40) DEFAULT '' , 711 log_time number(11) DEFAULT '0' NOT NULL, 712 log_operation clob DEFAULT '' , 713 log_data clob DEFAULT '' , 714 CONSTRAINT pk_phpbb_log PRIMARY KEY (log_id) 715 ) 716 / 717 718 CREATE INDEX phpbb_log_log_type ON phpbb_log (log_type) 719 / 720 CREATE INDEX phpbb_log_forum_id ON phpbb_log (forum_id) 721 / 722 CREATE INDEX phpbb_log_topic_id ON phpbb_log (topic_id) 723 / 724 CREATE INDEX phpbb_log_reportee_id ON phpbb_log (reportee_id) 725 / 726 CREATE INDEX phpbb_log_user_id ON phpbb_log (user_id) 727 / 728 729 CREATE SEQUENCE phpbb_log_seq 730 / 731 732 CREATE OR REPLACE TRIGGER t_phpbb_log 733 BEFORE INSERT ON phpbb_log 734 FOR EACH ROW WHEN ( 735 new.log_id IS NULL OR new.log_id = 0 736 ) 737 BEGIN 738 SELECT phpbb_log_seq.nextval 739 INTO :new.log_id 740 FROM dual; 741 END; 742 / 743 744 745 /* 746 Table: 'phpbb_login_attempts' 747 */ 748 CREATE TABLE phpbb_login_attempts ( 749 attempt_ip varchar2(40) DEFAULT '' , 750 attempt_browser varchar2(150) DEFAULT '' , 751 attempt_forwarded_for varchar2(255) DEFAULT '' , 752 attempt_time number(11) DEFAULT '0' NOT NULL, 753 user_id number(8) DEFAULT '0' NOT NULL, 754 username varchar2(765) DEFAULT '0' NOT NULL, 755 username_clean varchar2(255) DEFAULT '0' NOT NULL 756 ) 757 / 758 759 CREATE INDEX phpbb_login_attempts_att_ip ON phpbb_login_attempts (attempt_ip, attempt_time) 760 / 761 CREATE INDEX phpbb_login_attempts_att_for ON phpbb_login_attempts (attempt_forwarded_for, attempt_time) 762 / 763 CREATE INDEX phpbb_login_attempts_att_time ON phpbb_login_attempts (attempt_time) 764 / 765 CREATE INDEX phpbb_login_attempts_user_id ON phpbb_login_attempts (user_id) 766 / 767 768 /* 769 Table: 'phpbb_moderator_cache' 770 */ 771 CREATE TABLE phpbb_moderator_cache ( 772 forum_id number(8) DEFAULT '0' NOT NULL, 773 user_id number(8) DEFAULT '0' NOT NULL, 774 username varchar2(765) DEFAULT '' , 775 group_id number(8) DEFAULT '0' NOT NULL, 776 group_name varchar2(765) DEFAULT '' , 777 display_on_index number(1) DEFAULT '1' NOT NULL 778 ) 779 / 780 781 CREATE INDEX phpbb_moderator_cache_disp_idx ON phpbb_moderator_cache (display_on_index) 782 / 783 CREATE INDEX phpbb_moderator_cache_forum_id ON phpbb_moderator_cache (forum_id) 784 / 785 786 /* 787 Table: 'phpbb_modules' 788 */ 789 CREATE TABLE phpbb_modules ( 790 module_id number(8) NOT NULL, 791 module_enabled number(1) DEFAULT '1' NOT NULL, 792 module_display number(1) DEFAULT '1' NOT NULL, 793 module_basename varchar2(255) DEFAULT '' , 794 module_class varchar2(10) DEFAULT '' , 795 parent_id number(8) DEFAULT '0' NOT NULL, 796 left_id number(8) DEFAULT '0' NOT NULL, 797 right_id number(8) DEFAULT '0' NOT NULL, 798 module_langname varchar2(255) DEFAULT '' , 799 module_mode varchar2(255) DEFAULT '' , 800 module_auth varchar2(255) DEFAULT '' , 801 CONSTRAINT pk_phpbb_modules PRIMARY KEY (module_id) 802 ) 803 / 804 805 CREATE INDEX phpbb_modules_left_right_id ON phpbb_modules (left_id, right_id) 806 / 807 CREATE INDEX phpbb_modules_module_enabled ON phpbb_modules (module_enabled) 808 / 809 CREATE INDEX phpbb_modules_class_left_id ON phpbb_modules (module_class, left_id) 810 / 811 812 CREATE SEQUENCE phpbb_modules_seq 813 / 814 815 CREATE OR REPLACE TRIGGER t_phpbb_modules 816 BEFORE INSERT ON phpbb_modules 817 FOR EACH ROW WHEN ( 818 new.module_id IS NULL OR new.module_id = 0 819 ) 820 BEGIN 821 SELECT phpbb_modules_seq.nextval 822 INTO :new.module_id 823 FROM dual; 824 END; 825 / 826 827 828 /* 829 Table: 'phpbb_poll_options' 830 */ 831 CREATE TABLE phpbb_poll_options ( 832 poll_option_id number(4) DEFAULT '0' NOT NULL, 833 topic_id number(8) DEFAULT '0' NOT NULL, 834 poll_option_text clob DEFAULT '' , 835 poll_option_total number(8) DEFAULT '0' NOT NULL 836 ) 837 / 838 839 CREATE INDEX phpbb_poll_options_poll_opt_id ON phpbb_poll_options (poll_option_id) 840 / 841 CREATE INDEX phpbb_poll_options_topic_id ON phpbb_poll_options (topic_id) 842 / 843 844 /* 845 Table: 'phpbb_poll_votes' 846 */ 847 CREATE TABLE phpbb_poll_votes ( 848 topic_id number(8) DEFAULT '0' NOT NULL, 849 poll_option_id number(4) DEFAULT '0' NOT NULL, 850 vote_user_id number(8) DEFAULT '0' NOT NULL, 851 vote_user_ip varchar2(40) DEFAULT '' 852 ) 853 / 854 855 CREATE INDEX phpbb_poll_votes_topic_id ON phpbb_poll_votes (topic_id) 856 / 857 CREATE INDEX phpbb_poll_votes_vote_user_id ON phpbb_poll_votes (vote_user_id) 858 / 859 CREATE INDEX phpbb_poll_votes_vote_user_ip ON phpbb_poll_votes (vote_user_ip) 860 / 861 862 /* 863 Table: 'phpbb_posts' 864 */ 865 CREATE TABLE phpbb_posts ( 866 post_id number(8) NOT NULL, 867 topic_id number(8) DEFAULT '0' NOT NULL, 868 forum_id number(8) DEFAULT '0' NOT NULL, 869 poster_id number(8) DEFAULT '0' NOT NULL, 870 icon_id number(8) DEFAULT '0' NOT NULL, 871 poster_ip varchar2(40) DEFAULT '' , 872 post_time number(11) DEFAULT '0' NOT NULL, 873 post_approved number(1) DEFAULT '1' NOT NULL, 874 post_reported number(1) DEFAULT '0' NOT NULL, 875 enable_bbcode number(1) DEFAULT '1' NOT NULL, 876 enable_smilies number(1) DEFAULT '1' NOT NULL, 877 enable_magic_url number(1) DEFAULT '1' NOT NULL, 878 enable_sig number(1) DEFAULT '1' NOT NULL, 879 post_username varchar2(765) DEFAULT '' , 880 post_subject varchar2(765) DEFAULT '' , 881 post_text clob DEFAULT '' , 882 post_checksum varchar2(32) DEFAULT '' , 883 post_attachment number(1) DEFAULT '0' NOT NULL, 884 bbcode_bitfield varchar2(255) DEFAULT '' , 885 bbcode_uid varchar2(8) DEFAULT '' , 886 post_postcount number(1) DEFAULT '1' NOT NULL, 887 post_edit_time number(11) DEFAULT '0' NOT NULL, 888 post_edit_reason varchar2(765) DEFAULT '' , 889 post_edit_user number(8) DEFAULT '0' NOT NULL, 890 post_edit_count number(4) DEFAULT '0' NOT NULL, 891 post_edit_locked number(1) DEFAULT '0' NOT NULL, 892 CONSTRAINT pk_phpbb_posts PRIMARY KEY (post_id) 893 ) 894 / 895 896 CREATE INDEX phpbb_posts_forum_id ON phpbb_posts (forum_id) 897 / 898 CREATE INDEX phpbb_posts_topic_id ON phpbb_posts (topic_id) 899 / 900 CREATE INDEX phpbb_posts_poster_ip ON phpbb_posts (poster_ip) 901 / 902 CREATE INDEX phpbb_posts_poster_id ON phpbb_posts (poster_id) 903 / 904 CREATE INDEX phpbb_posts_post_approved ON phpbb_posts (post_approved) 905 / 906 CREATE INDEX phpbb_posts_post_username ON phpbb_posts (post_username) 907 / 908 CREATE INDEX phpbb_posts_tid_post_time ON phpbb_posts (topic_id, post_time) 909 / 910 911 CREATE SEQUENCE phpbb_posts_seq 912 / 913 914 CREATE OR REPLACE TRIGGER t_phpbb_posts 915 BEFORE INSERT ON phpbb_posts 916 FOR EACH ROW WHEN ( 917 new.post_id IS NULL OR new.post_id = 0 918 ) 919 BEGIN 920 SELECT phpbb_posts_seq.nextval 921 INTO :new.post_id 922 FROM dual; 923 END; 924 / 925 926 927 /* 928 Table: 'phpbb_privmsgs' 929 */ 930 CREATE TABLE phpbb_privmsgs ( 931 msg_id number(8) NOT NULL, 932 root_level number(8) DEFAULT '0' NOT NULL, 933 author_id number(8) DEFAULT '0' NOT NULL, 934 icon_id number(8) DEFAULT '0' NOT NULL, 935 author_ip varchar2(40) DEFAULT '' , 936 message_time number(11) DEFAULT '0' NOT NULL, 937 enable_bbcode number(1) DEFAULT '1' NOT NULL, 938 enable_smilies number(1) DEFAULT '1' NOT NULL, 939 enable_magic_url number(1) DEFAULT '1' NOT NULL, 940 enable_sig number(1) DEFAULT '1' NOT NULL, 941 message_subject varchar2(765) DEFAULT '' , 942 message_text clob DEFAULT '' , 943 message_edit_reason varchar2(765) DEFAULT '' , 944 message_edit_user number(8) DEFAULT '0' NOT NULL, 945 message_attachment number(1) DEFAULT '0' NOT NULL, 946 bbcode_bitfield varchar2(255) DEFAULT '' , 947 bbcode_uid varchar2(8) DEFAULT '' , 948 message_edit_time number(11) DEFAULT '0' NOT NULL, 949 message_edit_count number(4) DEFAULT '0' NOT NULL, 950 to_address clob DEFAULT '' , 951 bcc_address clob DEFAULT '' , 952 message_reported number(1) DEFAULT '0' NOT NULL, 953 CONSTRAINT pk_phpbb_privmsgs PRIMARY KEY (msg_id) 954 ) 955 / 956 957 CREATE INDEX phpbb_privmsgs_author_ip ON phpbb_privmsgs (author_ip) 958 / 959 CREATE INDEX phpbb_privmsgs_message_time ON phpbb_privmsgs (message_time) 960 / 961 CREATE INDEX phpbb_privmsgs_author_id ON phpbb_privmsgs (author_id) 962 / 963 CREATE INDEX phpbb_privmsgs_root_level ON phpbb_privmsgs (root_level) 964 / 965 966 CREATE SEQUENCE phpbb_privmsgs_seq 967 / 968 969 CREATE OR REPLACE TRIGGER t_phpbb_privmsgs 970 BEFORE INSERT ON phpbb_privmsgs 971 FOR EACH ROW WHEN ( 972 new.msg_id IS NULL OR new.msg_id = 0 973 ) 974 BEGIN 975 SELECT phpbb_privmsgs_seq.nextval 976 INTO :new.msg_id 977 FROM dual; 978 END; 979 / 980 981 982 /* 983 Table: 'phpbb_privmsgs_folder' 984 */ 985 CREATE TABLE phpbb_privmsgs_folder ( 986 folder_id number(8) NOT NULL, 987 user_id number(8) DEFAULT '0' NOT NULL, 988 folder_name varchar2(765) DEFAULT '' , 989 pm_count number(8) DEFAULT '0' NOT NULL, 990 CONSTRAINT pk_phpbb_privmsgs_folder PRIMARY KEY (folder_id) 991 ) 992 / 993 994 CREATE INDEX phpbb_privmsgs_folder_user_id ON phpbb_privmsgs_folder (user_id) 995 / 996 997 CREATE SEQUENCE phpbb_privmsgs_folder_seq 998 / 999 1000 CREATE OR REPLACE TRIGGER t_phpbb_privmsgs_folder 1001 BEFORE INSERT ON phpbb_privmsgs_folder 1002 FOR EACH ROW WHEN ( 1003 new.folder_id IS NULL OR new.folder_id = 0 1004 ) 1005 BEGIN 1006 SELECT phpbb_privmsgs_folder_seq.nextval 1007 INTO :new.folder_id 1008 FROM dual; 1009 END; 1010 / 1011 1012 1013 /* 1014 Table: 'phpbb_privmsgs_rules' 1015 */ 1016 CREATE TABLE phpbb_privmsgs_rules ( 1017 rule_id number(8) NOT NULL, 1018 user_id number(8) DEFAULT '0' NOT NULL, 1019 rule_check number(8) DEFAULT '0' NOT NULL, 1020 rule_connection number(8) DEFAULT '0' NOT NULL, 1021 rule_string varchar2(765) DEFAULT '' , 1022 rule_user_id number(8) DEFAULT '0' NOT NULL, 1023 rule_group_id number(8) DEFAULT '0' NOT NULL, 1024 rule_action number(8) DEFAULT '0' NOT NULL, 1025 rule_folder_id number(11) DEFAULT '0' NOT NULL, 1026 CONSTRAINT pk_phpbb_privmsgs_rules PRIMARY KEY (rule_id) 1027 ) 1028 / 1029 1030 CREATE INDEX phpbb_privmsgs_rules_user_id ON phpbb_privmsgs_rules (user_id) 1031 / 1032 1033 CREATE SEQUENCE phpbb_privmsgs_rules_seq 1034 / 1035 1036 CREATE OR REPLACE TRIGGER t_phpbb_privmsgs_rules 1037 BEFORE INSERT ON phpbb_privmsgs_rules 1038 FOR EACH ROW WHEN ( 1039 new.rule_id IS NULL OR new.rule_id = 0 1040 ) 1041 BEGIN 1042 SELECT phpbb_privmsgs_rules_seq.nextval 1043 INTO :new.rule_id 1044 FROM dual; 1045 END; 1046 / 1047 1048 1049 /* 1050 Table: 'phpbb_privmsgs_to' 1051 */ 1052 CREATE TABLE phpbb_privmsgs_to ( 1053 msg_id number(8) DEFAULT '0' NOT NULL, 1054 user_id number(8) DEFAULT '0' NOT NULL, 1055 author_id number(8) DEFAULT '0' NOT NULL, 1056 pm_deleted number(1) DEFAULT '0' NOT NULL, 1057 pm_new number(1) DEFAULT '1' NOT NULL, 1058 pm_unread number(1) DEFAULT '1' NOT NULL, 1059 pm_replied number(1) DEFAULT '0' NOT NULL, 1060 pm_marked number(1) DEFAULT '0' NOT NULL, 1061 pm_forwarded number(1) DEFAULT '0' NOT NULL, 1062 folder_id number(11) DEFAULT '0' NOT NULL 1063 ) 1064 / 1065 1066 CREATE INDEX phpbb_privmsgs_to_msg_id ON phpbb_privmsgs_to (msg_id) 1067 / 1068 CREATE INDEX phpbb_privmsgs_to_author_id ON phpbb_privmsgs_to (author_id) 1069 / 1070 CREATE INDEX phpbb_privmsgs_to_usr_flder_id ON phpbb_privmsgs_to (user_id, folder_id) 1071 / 1072 1073 /* 1074 Table: 'phpbb_profile_fields' 1075 */ 1076 CREATE TABLE phpbb_profile_fields ( 1077 field_id number(8) NOT NULL, 1078 field_name varchar2(765) DEFAULT '' , 1079 field_type number(4) DEFAULT '0' NOT NULL, 1080 field_ident varchar2(20) DEFAULT '' , 1081 field_length varchar2(20) DEFAULT '' , 1082 field_minlen varchar2(255) DEFAULT '' , 1083 field_maxlen varchar2(255) DEFAULT '' , 1084 field_novalue varchar2(765) DEFAULT '' , 1085 field_default_value varchar2(765) DEFAULT '' , 1086 field_validation varchar2(60) DEFAULT '' , 1087 field_required number(1) DEFAULT '0' NOT NULL, 1088 field_show_novalue number(1) DEFAULT '0' NOT NULL, 1089 field_show_on_reg number(1) DEFAULT '0' NOT NULL, 1090 field_show_on_vt number(1) DEFAULT '0' NOT NULL, 1091 field_show_profile number(1) DEFAULT '0' NOT NULL, 1092 field_hide number(1) DEFAULT '0' NOT NULL, 1093 field_no_view number(1) DEFAULT '0' NOT NULL, 1094 field_active number(1) DEFAULT '0' NOT NULL, 1095 field_order number(8) DEFAULT '0' NOT NULL, 1096 CONSTRAINT pk_phpbb_profile_fields PRIMARY KEY (field_id) 1097 ) 1098 / 1099 1100 CREATE INDEX phpbb_profile_fields_fld_type ON phpbb_profile_fields (field_type) 1101 / 1102 CREATE INDEX phpbb_profile_fields_fld_ordr ON phpbb_profile_fields (field_order) 1103 / 1104 1105 CREATE SEQUENCE phpbb_profile_fields_seq 1106 / 1107 1108 CREATE OR REPLACE TRIGGER t_phpbb_profile_fields 1109 BEFORE INSERT ON phpbb_profile_fields 1110 FOR EACH ROW WHEN ( 1111 new.field_id IS NULL OR new.field_id = 0 1112 ) 1113 BEGIN 1114 SELECT phpbb_profile_fields_seq.nextval 1115 INTO :new.field_id 1116 FROM dual; 1117 END; 1118 / 1119 1120 1121 /* 1122 Table: 'phpbb_profile_fields_data' 1123 */ 1124 CREATE TABLE phpbb_profile_fields_data ( 1125 user_id number(8) DEFAULT '0' NOT NULL, 1126 CONSTRAINT pk_phpbb_profile_fields_data PRIMARY KEY (user_id) 1127 ) 1128 / 1129 1130 1131 /* 1132 Table: 'phpbb_profile_fields_lang' 1133 */ 1134 CREATE TABLE phpbb_profile_fields_lang ( 1135 field_id number(8) DEFAULT '0' NOT NULL, 1136 lang_id number(8) DEFAULT '0' NOT NULL, 1137 option_id number(8) DEFAULT '0' NOT NULL, 1138 field_type number(4) DEFAULT '0' NOT NULL, 1139 lang_value varchar2(765) DEFAULT '' , 1140 CONSTRAINT pk_phpbb_profile_fields_lang PRIMARY KEY (field_id, lang_id, option_id) 1141 ) 1142 / 1143 1144 1145 /* 1146 Table: 'phpbb_profile_lang' 1147 */ 1148 CREATE TABLE phpbb_profile_lang ( 1149 field_id number(8) DEFAULT '0' NOT NULL, 1150 lang_id number(8) DEFAULT '0' NOT NULL, 1151 lang_name varchar2(765) DEFAULT '' , 1152 lang_explain clob DEFAULT '' , 1153 lang_default_value varchar2(765) DEFAULT '' , 1154 CONSTRAINT pk_phpbb_profile_lang PRIMARY KEY (field_id, lang_id) 1155 ) 1156 / 1157 1158 1159 /* 1160 Table: 'phpbb_ranks' 1161 */ 1162 CREATE TABLE phpbb_ranks ( 1163 rank_id number(8) NOT NULL, 1164 rank_title varchar2(765) DEFAULT '' , 1165 rank_min number(8) DEFAULT '0' NOT NULL, 1166 rank_special number(1) DEFAULT '0' NOT NULL, 1167 rank_image varchar2(255) DEFAULT '' , 1168 CONSTRAINT pk_phpbb_ranks PRIMARY KEY (rank_id) 1169 ) 1170 / 1171 1172 1173 CREATE SEQUENCE phpbb_ranks_seq 1174 / 1175 1176 CREATE OR REPLACE TRIGGER t_phpbb_ranks 1177 BEFORE INSERT ON phpbb_ranks 1178 FOR EACH ROW WHEN ( 1179 new.rank_id IS NULL OR new.rank_id = 0 1180 ) 1181 BEGIN 1182 SELECT phpbb_ranks_seq.nextval 1183 INTO :new.rank_id 1184 FROM dual; 1185 END; 1186 / 1187 1188 1189 /* 1190 Table: 'phpbb_reports' 1191 */ 1192 CREATE TABLE phpbb_reports ( 1193 report_id number(8) NOT NULL, 1194 reason_id number(4) DEFAULT '0' NOT NULL, 1195 post_id number(8) DEFAULT '0' NOT NULL, 1196 pm_id number(8) DEFAULT '0' NOT NULL, 1197 user_id number(8) DEFAULT '0' NOT NULL, 1198 user_notify number(1) DEFAULT '0' NOT NULL, 1199 report_closed number(1) DEFAULT '0' NOT NULL, 1200 report_time number(11) DEFAULT '0' NOT NULL, 1201 report_text clob DEFAULT '' , 1202 CONSTRAINT pk_phpbb_reports PRIMARY KEY (report_id) 1203 ) 1204 / 1205 1206 CREATE INDEX phpbb_reports_post_id ON phpbb_reports (post_id) 1207 / 1208 CREATE INDEX phpbb_reports_pm_id ON phpbb_reports (pm_id) 1209 / 1210 1211 CREATE SEQUENCE phpbb_reports_seq 1212 / 1213 1214 CREATE OR REPLACE TRIGGER t_phpbb_reports 1215 BEFORE INSERT ON phpbb_reports 1216 FOR EACH ROW WHEN ( 1217 new.report_id IS NULL OR new.report_id = 0 1218 ) 1219 BEGIN 1220 SELECT phpbb_reports_seq.nextval 1221 INTO :new.report_id 1222 FROM dual; 1223 END; 1224 / 1225 1226 1227 /* 1228 Table: 'phpbb_reports_reasons' 1229 */ 1230 CREATE TABLE phpbb_reports_reasons ( 1231 reason_id number(4) NOT NULL, 1232 reason_title varchar2(765) DEFAULT '' , 1233 reason_description clob DEFAULT '' , 1234 reason_order number(4) DEFAULT '0' NOT NULL, 1235 CONSTRAINT pk_phpbb_reports_reasons PRIMARY KEY (reason_id) 1236 ) 1237 / 1238 1239 1240 CREATE SEQUENCE phpbb_reports_reasons_seq 1241 / 1242 1243 CREATE OR REPLACE TRIGGER t_phpbb_reports_reasons 1244 BEFORE INSERT ON phpbb_reports_reasons 1245 FOR EACH ROW WHEN ( 1246 new.reason_id IS NULL OR new.reason_id = 0 1247 ) 1248 BEGIN 1249 SELECT phpbb_reports_reasons_seq.nextval 1250 INTO :new.reason_id 1251 FROM dual; 1252 END; 1253 / 1254 1255 1256 /* 1257 Table: 'phpbb_search_results' 1258 */ 1259 CREATE TABLE phpbb_search_results ( 1260 search_key varchar2(32) DEFAULT '' , 1261 search_time number(11) DEFAULT '0' NOT NULL, 1262 search_keywords clob DEFAULT '' , 1263 search_authors clob DEFAULT '' , 1264 CONSTRAINT pk_phpbb_search_results PRIMARY KEY (search_key) 1265 ) 1266 / 1267 1268 1269 /* 1270 Table: 'phpbb_search_wordlist' 1271 */ 1272 CREATE TABLE phpbb_search_wordlist ( 1273 word_id number(8) NOT NULL, 1274 word_text varchar2(765) DEFAULT '' , 1275 word_common number(1) DEFAULT '0' NOT NULL, 1276 word_count number(8) DEFAULT '0' NOT NULL, 1277 CONSTRAINT pk_phpbb_search_wordlist PRIMARY KEY (word_id), 1278 CONSTRAINT u_phpbb_wrd_txt UNIQUE (word_text) 1279 ) 1280 / 1281 1282 CREATE INDEX phpbb_search_wordlist_wrd_cnt ON phpbb_search_wordlist (word_count) 1283 / 1284 1285 CREATE SEQUENCE phpbb_search_wordlist_seq 1286 / 1287 1288 CREATE OR REPLACE TRIGGER t_phpbb_search_wordlist 1289 BEFORE INSERT ON phpbb_search_wordlist 1290 FOR EACH ROW WHEN ( 1291 new.word_id IS NULL OR new.word_id = 0 1292 ) 1293 BEGIN 1294 SELECT phpbb_search_wordlist_seq.nextval 1295 INTO :new.word_id 1296 FROM dual; 1297 END; 1298 / 1299 1300 1301 /* 1302 Table: 'phpbb_search_wordmatch' 1303 */ 1304 CREATE TABLE phpbb_search_wordmatch ( 1305 post_id number(8) DEFAULT '0' NOT NULL, 1306 word_id number(8) DEFAULT '0' NOT NULL, 1307 title_match number(1) DEFAULT '0' NOT NULL, 1308 CONSTRAINT u_phpbb_unq_mtch UNIQUE (word_id, post_id, title_match) 1309 ) 1310 / 1311 1312 CREATE INDEX phpbb_search_wordmatch_word_id ON phpbb_search_wordmatch (word_id) 1313 / 1314 CREATE INDEX phpbb_search_wordmatch_post_id ON phpbb_search_wordmatch (post_id) 1315 / 1316 1317 /* 1318 Table: 'phpbb_sessions' 1319 */ 1320 CREATE TABLE phpbb_sessions ( 1321 session_id char(32) DEFAULT '' , 1322 session_user_id number(8) DEFAULT '0' NOT NULL, 1323 session_forum_id number(8) DEFAULT '0' NOT NULL, 1324 session_last_visit number(11) DEFAULT '0' NOT NULL, 1325 session_start number(11) DEFAULT '0' NOT NULL, 1326 session_time number(11) DEFAULT '0' NOT NULL, 1327 session_ip varchar2(40) DEFAULT '' , 1328 session_browser varchar2(150) DEFAULT '' , 1329 session_forwarded_for varchar2(255) DEFAULT '' , 1330 session_page varchar2(765) DEFAULT '' , 1331 session_viewonline number(1) DEFAULT '1' NOT NULL, 1332 session_autologin number(1) DEFAULT '0' NOT NULL, 1333 session_admin number(1) DEFAULT '0' NOT NULL, 1334 CONSTRAINT pk_phpbb_sessions PRIMARY KEY (session_id) 1335 ) 1336 / 1337 1338 CREATE INDEX phpbb_sessions_session_time ON phpbb_sessions (session_time) 1339 / 1340 CREATE INDEX phpbb_sessions_session_user_id ON phpbb_sessions (session_user_id) 1341 / 1342 CREATE INDEX phpbb_sessions_session_fid ON phpbb_sessions (session_forum_id) 1343 / 1344 1345 /* 1346 Table: 'phpbb_sessions_keys' 1347 */ 1348 CREATE TABLE phpbb_sessions_keys ( 1349 key_id char(32) DEFAULT '' , 1350 user_id number(8) DEFAULT '0' NOT NULL, 1351 last_ip varchar2(40) DEFAULT '' , 1352 last_login number(11) DEFAULT '0' NOT NULL, 1353 CONSTRAINT pk_phpbb_sessions_keys PRIMARY KEY (key_id, user_id) 1354 ) 1355 / 1356 1357 CREATE INDEX phpbb_sessions_keys_last_login ON phpbb_sessions_keys (last_login) 1358 / 1359 1360 /* 1361 Table: 'phpbb_sitelist' 1362 */ 1363 CREATE TABLE phpbb_sitelist ( 1364 site_id number(8) NOT NULL, 1365 site_ip varchar2(40) DEFAULT '' , 1366 site_hostname varchar2(255) DEFAULT '' , 1367 ip_exclude number(1) DEFAULT '0' NOT NULL, 1368 CONSTRAINT pk_phpbb_sitelist PRIMARY KEY (site_id) 1369 ) 1370 / 1371 1372 1373 CREATE SEQUENCE phpbb_sitelist_seq 1374 / 1375 1376 CREATE OR REPLACE TRIGGER t_phpbb_sitelist 1377 BEFORE INSERT ON phpbb_sitelist 1378 FOR EACH ROW WHEN ( 1379 new.site_id IS NULL OR new.site_id = 0 1380 ) 1381 BEGIN 1382 SELECT phpbb_sitelist_seq.nextval 1383 INTO :new.site_id 1384 FROM dual; 1385 END; 1386 / 1387 1388 1389 /* 1390 Table: 'phpbb_smilies' 1391 */ 1392 CREATE TABLE phpbb_smilies ( 1393 smiley_id number(8) NOT NULL, 1394 code varchar2(150) DEFAULT '' , 1395 emotion varchar2(150) DEFAULT '' , 1396 smiley_url varchar2(50) DEFAULT '' , 1397 smiley_width number(4) DEFAULT '0' NOT NULL, 1398 smiley_height number(4) DEFAULT '0' NOT NULL, 1399 smiley_order number(8) DEFAULT '0' NOT NULL, 1400 display_on_posting number(1) DEFAULT '1' NOT NULL, 1401 CONSTRAINT pk_phpbb_smilies PRIMARY KEY (smiley_id) 1402 ) 1403 / 1404 1405 CREATE INDEX phpbb_smilies_display_on_post ON phpbb_smilies (display_on_posting) 1406 / 1407 1408 CREATE SEQUENCE phpbb_smilies_seq 1409 / 1410 1411 CREATE OR REPLACE TRIGGER t_phpbb_smilies 1412 BEFORE INSERT ON phpbb_smilies 1413 FOR EACH ROW WHEN ( 1414 new.smiley_id IS NULL OR new.smiley_id = 0 1415 ) 1416 BEGIN 1417 SELECT phpbb_smilies_seq.nextval 1418 INTO :new.smiley_id 1419 FROM dual; 1420 END; 1421 / 1422 1423 1424 /* 1425 Table: 'phpbb_styles' 1426 */ 1427 CREATE TABLE phpbb_styles ( 1428 style_id number(8) NOT NULL, 1429 style_name varchar2(765) DEFAULT '' , 1430 style_copyright varchar2(765) DEFAULT '' , 1431 style_active number(1) DEFAULT '1' NOT NULL, 1432 template_id number(8) DEFAULT '0' NOT NULL, 1433 theme_id number(8) DEFAULT '0' NOT NULL, 1434 imageset_id number(8) DEFAULT '0' NOT NULL, 1435 CONSTRAINT pk_phpbb_styles PRIMARY KEY (style_id), 1436 CONSTRAINT u_phpbb_style_name UNIQUE (style_name) 1437 ) 1438 / 1439 1440 CREATE INDEX phpbb_styles_template_id ON phpbb_styles (template_id) 1441 / 1442 CREATE INDEX phpbb_styles_theme_id ON phpbb_styles (theme_id) 1443 / 1444 CREATE INDEX phpbb_styles_imageset_id ON phpbb_styles (imageset_id) 1445 / 1446 1447 CREATE SEQUENCE phpbb_styles_seq 1448 / 1449 1450 CREATE OR REPLACE TRIGGER t_phpbb_styles 1451 BEFORE INSERT ON phpbb_styles 1452 FOR EACH ROW WHEN ( 1453 new.style_id IS NULL OR new.style_id = 0 1454 ) 1455 BEGIN 1456 SELECT phpbb_styles_seq.nextval 1457 INTO :new.style_id 1458 FROM dual; 1459 END; 1460 / 1461 1462 1463 /* 1464 Table: 'phpbb_styles_template' 1465 */ 1466 CREATE TABLE phpbb_styles_template ( 1467 template_id number(8) NOT NULL, 1468 template_name varchar2(765) DEFAULT '' , 1469 template_copyright varchar2(765) DEFAULT '' , 1470 template_path varchar2(100) DEFAULT '' , 1471 bbcode_bitfield varchar2(255) DEFAULT 'kNg=' NOT NULL, 1472 template_storedb number(1) DEFAULT '0' NOT NULL, 1473 template_inherits_id number(4) DEFAULT '0' NOT NULL, 1474 template_inherit_path varchar2(255) DEFAULT '' , 1475 CONSTRAINT pk_phpbb_styles_template PRIMARY KEY (template_id), 1476 CONSTRAINT u_phpbb_tmplte_nm UNIQUE (template_name) 1477 ) 1478 / 1479 1480 1481 CREATE SEQUENCE phpbb_styles_template_seq 1482 / 1483 1484 CREATE OR REPLACE TRIGGER t_phpbb_styles_template 1485 BEFORE INSERT ON phpbb_styles_template 1486 FOR EACH ROW WHEN ( 1487 new.template_id IS NULL OR new.template_id = 0 1488 ) 1489 BEGIN 1490 SELECT phpbb_styles_template_seq.nextval 1491 INTO :new.template_id 1492 FROM dual; 1493 END; 1494 / 1495 1496 1497 /* 1498 Table: 'phpbb_styles_template_data' 1499 */ 1500 CREATE TABLE phpbb_styles_template_data ( 1501 template_id number(8) DEFAULT '0' NOT NULL, 1502 template_filename varchar2(100) DEFAULT '' , 1503 template_included clob DEFAULT '' , 1504 template_mtime number(11) DEFAULT '0' NOT NULL, 1505 template_data clob DEFAULT '' 1506 ) 1507 / 1508 1509 CREATE INDEX phpbb_styles_template_data_tid ON phpbb_styles_template_data (template_id) 1510 / 1511 CREATE INDEX phpbb_styles_template_data_tfn ON phpbb_styles_template_data (template_filename) 1512 / 1513 1514 /* 1515 Table: 'phpbb_styles_theme' 1516 */ 1517 CREATE TABLE phpbb_styles_theme ( 1518 theme_id number(8) NOT NULL, 1519 theme_name varchar2(765) DEFAULT '' , 1520 theme_copyright varchar2(765) DEFAULT '' , 1521 theme_path varchar2(100) DEFAULT '' , 1522 theme_storedb number(1) DEFAULT '0' NOT NULL, 1523 theme_mtime number(11) DEFAULT '0' NOT NULL, 1524 theme_data clob DEFAULT '' , 1525 CONSTRAINT pk_phpbb_styles_theme PRIMARY KEY (theme_id), 1526 CONSTRAINT u_phpbb_theme_name UNIQUE (theme_name) 1527 ) 1528 / 1529 1530 1531 CREATE SEQUENCE phpbb_styles_theme_seq 1532 / 1533 1534 CREATE OR REPLACE TRIGGER t_phpbb_styles_theme 1535 BEFORE INSERT ON phpbb_styles_theme 1536 FOR EACH ROW WHEN ( 1537 new.theme_id IS NULL OR new.theme_id = 0 1538 ) 1539 BEGIN 1540 SELECT phpbb_styles_theme_seq.nextval 1541 INTO :new.theme_id 1542 FROM dual; 1543 END; 1544 / 1545 1546 1547 /* 1548 Table: 'phpbb_styles_imageset' 1549 */ 1550 CREATE TABLE phpbb_styles_imageset ( 1551 imageset_id number(8) NOT NULL, 1552 imageset_name varchar2(765) DEFAULT '' , 1553 imageset_copyright varchar2(765) DEFAULT '' , 1554 imageset_path varchar2(100) DEFAULT '' , 1555 CONSTRAINT pk_phpbb_styles_imageset PRIMARY KEY (imageset_id), 1556 CONSTRAINT u_phpbb_imgset_nm UNIQUE (imageset_name) 1557 ) 1558 / 1559 1560 1561 CREATE SEQUENCE phpbb_styles_imageset_seq 1562 / 1563 1564 CREATE OR REPLACE TRIGGER t_phpbb_styles_imageset 1565 BEFORE INSERT ON phpbb_styles_imageset 1566 FOR EACH ROW WHEN ( 1567 new.imageset_id IS NULL OR new.imageset_id = 0 1568 ) 1569 BEGIN 1570 SELECT phpbb_styles_imageset_seq.nextval 1571 INTO :new.imageset_id 1572 FROM dual; 1573 END; 1574 / 1575 1576 1577 /* 1578 Table: 'phpbb_styles_imageset_data' 1579 */ 1580 CREATE TABLE phpbb_styles_imageset_data ( 1581 image_id number(8) NOT NULL, 1582 image_name varchar2(200) DEFAULT '' , 1583 image_filename varchar2(200) DEFAULT '' , 1584 image_lang varchar2(30) DEFAULT '' , 1585 image_height number(4) DEFAULT '0' NOT NULL, 1586 image_width number(4) DEFAULT '0' NOT NULL, 1587 imageset_id number(8) DEFAULT '0' NOT NULL, 1588 CONSTRAINT pk_phpbb_styles_imageset_data PRIMARY KEY (image_id) 1589 ) 1590 / 1591 1592 CREATE INDEX phpbb_styles_imageset_data_i_d ON phpbb_styles_imageset_data (imageset_id) 1593 / 1594 1595 CREATE SEQUENCE phpbb_styles_imageset_data_seq 1596 / 1597 1598 CREATE OR REPLACE TRIGGER t_phpbb_styles_imageset_data 1599 BEFORE INSERT ON phpbb_styles_imageset_data 1600 FOR EACH ROW WHEN ( 1601 new.image_id IS NULL OR new.image_id = 0 1602 ) 1603 BEGIN 1604 SELECT phpbb_styles_imageset_data_seq.nextval 1605 INTO :new.image_id 1606 FROM dual; 1607 END; 1608 / 1609 1610 1611 /* 1612 Table: 'phpbb_topics' 1613 */ 1614 CREATE TABLE phpbb_topics ( 1615 topic_id number(8) NOT NULL, 1616 forum_id number(8) DEFAULT '0' NOT NULL, 1617 icon_id number(8) DEFAULT '0' NOT NULL, 1618 topic_attachment number(1) DEFAULT '0' NOT NULL, 1619 topic_approved number(1) DEFAULT '1' NOT NULL, 1620 topic_reported number(1) DEFAULT '0' NOT NULL, 1621 topic_title varchar2(765) DEFAULT '' , 1622 topic_poster number(8) DEFAULT '0' NOT NULL, 1623 topic_time number(11) DEFAULT '0' NOT NULL, 1624 topic_time_limit number(11) DEFAULT '0' NOT NULL, 1625 topic_views number(8) DEFAULT '0' NOT NULL, 1626 topic_replies number(8) DEFAULT '0' NOT NULL, 1627 topic_replies_real number(8) DEFAULT '0' NOT NULL, 1628 topic_status number(3) DEFAULT '0' NOT NULL, 1629 topic_type number(3) DEFAULT '0' NOT NULL, 1630 topic_first_post_id number(8) DEFAULT '0' NOT NULL, 1631 topic_first_poster_name varchar2(765) DEFAULT '' , 1632 topic_first_poster_colour varchar2(6) DEFAULT '' , 1633 topic_last_post_id number(8) DEFAULT '0' NOT NULL, 1634 topic_last_poster_id number(8) DEFAULT '0' NOT NULL, 1635 topic_last_poster_name varchar2(765) DEFAULT '' , 1636 topic_last_poster_colour varchar2(6) DEFAULT '' , 1637 topic_last_post_subject varchar2(765) DEFAULT '' , 1638 topic_last_post_time number(11) DEFAULT '0' NOT NULL, 1639 topic_last_view_time number(11) DEFAULT '0' NOT NULL, 1640 topic_moved_id number(8) DEFAULT '0' NOT NULL, 1641 topic_bumped number(1) DEFAULT '0' NOT NULL, 1642 topic_bumper number(8) DEFAULT '0' NOT NULL, 1643 poll_title varchar2(765) DEFAULT '' , 1644 poll_start number(11) DEFAULT '0' NOT NULL, 1645 poll_length number(11) DEFAULT '0' NOT NULL, 1646 poll_max_options number(4) DEFAULT '1' NOT NULL, 1647 poll_last_vote number(11) DEFAULT '0' NOT NULL, 1648 poll_vote_change number(1) DEFAULT '0' NOT NULL, 1649 CONSTRAINT pk_phpbb_topics PRIMARY KEY (topic_id) 1650 ) 1651 / 1652 1653 CREATE INDEX phpbb_topics_forum_id ON phpbb_topics (forum_id) 1654 / 1655 CREATE INDEX phpbb_topics_forum_id_type ON phpbb_topics (forum_id, topic_type) 1656 / 1657 CREATE INDEX phpbb_topics_last_post_time ON phpbb_topics (topic_last_post_time) 1658 / 1659 CREATE INDEX phpbb_topics_topic_approved ON phpbb_topics (topic_approved) 1660 / 1661 CREATE INDEX phpbb_topics_forum_appr_last ON phpbb_topics (forum_id, topic_approved, topic_last_post_id) 1662 / 1663 CREATE INDEX phpbb_topics_fid_time_moved ON phpbb_topics (forum_id, topic_last_post_time, topic_moved_id) 1664 / 1665 1666 CREATE SEQUENCE phpbb_topics_seq 1667 / 1668 1669 CREATE OR REPLACE TRIGGER t_phpbb_topics 1670 BEFORE INSERT ON phpbb_topics 1671 FOR EACH ROW WHEN ( 1672 new.topic_id IS NULL OR new.topic_id = 0 1673 ) 1674 BEGIN 1675 SELECT phpbb_topics_seq.nextval 1676 INTO :new.topic_id 1677 FROM dual; 1678 END; 1679 / 1680 1681 1682 /* 1683 Table: 'phpbb_topics_track' 1684 */ 1685 CREATE TABLE phpbb_topics_track ( 1686 user_id number(8) DEFAULT '0' NOT NULL, 1687 topic_id number(8) DEFAULT '0' NOT NULL, 1688 forum_id number(8) DEFAULT '0' NOT NULL, 1689 mark_time number(11) DEFAULT '0' NOT NULL, 1690 CONSTRAINT pk_phpbb_topics_track PRIMARY KEY (user_id, topic_id) 1691 ) 1692 / 1693 1694 CREATE INDEX phpbb_topics_track_topic_id ON phpbb_topics_track (topic_id) 1695 / 1696 CREATE INDEX phpbb_topics_track_forum_id ON phpbb_topics_track (forum_id) 1697 / 1698 1699 /* 1700 Table: 'phpbb_topics_posted' 1701 */ 1702 CREATE TABLE phpbb_topics_posted ( 1703 user_id number(8) DEFAULT '0' NOT NULL, 1704 topic_id number(8) DEFAULT '0' NOT NULL, 1705 topic_posted number(1) DEFAULT '0' NOT NULL, 1706 CONSTRAINT pk_phpbb_topics_posted PRIMARY KEY (user_id, topic_id) 1707 ) 1708 / 1709 1710 1711 /* 1712 Table: 'phpbb_topics_watch' 1713 */ 1714 CREATE TABLE phpbb_topics_watch ( 1715 topic_id number(8) DEFAULT '0' NOT NULL, 1716 user_id number(8) DEFAULT '0' NOT NULL, 1717 notify_status number(1) DEFAULT '0' NOT NULL 1718 ) 1719 / 1720 1721 CREATE INDEX phpbb_topics_watch_topic_id ON phpbb_topics_watch (topic_id) 1722 / 1723 CREATE INDEX phpbb_topics_watch_user_id ON phpbb_topics_watch (user_id) 1724 / 1725 CREATE INDEX phpbb_topics_watch_notify_stat ON phpbb_topics_watch (notify_status) 1726 / 1727 1728 /* 1729 Table: 'phpbb_user_group' 1730 */ 1731 CREATE TABLE phpbb_user_group ( 1732 group_id number(8) DEFAULT '0' NOT NULL, 1733 user_id number(8) DEFAULT '0' NOT NULL, 1734 group_leader number(1) DEFAULT '0' NOT NULL, 1735 user_pending number(1) DEFAULT '1' NOT NULL 1736 ) 1737 / 1738 1739 CREATE INDEX phpbb_user_group_group_id ON phpbb_user_group (group_id) 1740 / 1741 CREATE INDEX phpbb_user_group_user_id ON phpbb_user_group (user_id) 1742 / 1743 CREATE INDEX phpbb_user_group_group_leader ON phpbb_user_group (group_leader) 1744 / 1745 1746 /* 1747 Table: 'phpbb_users' 1748 */ 1749 CREATE TABLE phpbb_users ( 1750 user_id number(8) NOT NULL, 1751 user_type number(2) DEFAULT '0' NOT NULL, 1752 group_id number(8) DEFAULT '3' NOT NULL, 1753 user_permissions clob DEFAULT '' , 1754 user_perm_from number(8) DEFAULT '0' NOT NULL, 1755 user_ip varchar2(40) DEFAULT '' , 1756 user_regdate number(11) DEFAULT '0' NOT NULL, 1757 username varchar2(255) DEFAULT '' , 1758 username_clean varchar2(255) DEFAULT '' , 1759 user_password varchar2(120) DEFAULT '' , 1760 user_passchg number(11) DEFAULT '0' NOT NULL, 1761 user_pass_convert number(1) DEFAULT '0' NOT NULL, 1762 user_email varchar2(300) DEFAULT '' , 1763 user_email_hash number(20) DEFAULT '0' NOT NULL, 1764 user_birthday varchar2(10) DEFAULT '' , 1765 user_lastvisit number(11) DEFAULT '0' NOT NULL, 1766 user_lastmark number(11) DEFAULT '0' NOT NULL, 1767 user_lastpost_time number(11) DEFAULT '0' NOT NULL, 1768 user_lastpage varchar2(600) DEFAULT '' , 1769 user_last_confirm_key varchar2(10) DEFAULT '' , 1770 user_last_search number(11) DEFAULT '0' NOT NULL, 1771 user_warnings number(4) DEFAULT '0' NOT NULL, 1772 user_last_warning number(11) DEFAULT '0' NOT NULL, 1773 user_login_attempts number(4) DEFAULT '0' NOT NULL, 1774 user_inactive_reason number(2) DEFAULT '0' NOT NULL, 1775 user_inactive_time number(11) DEFAULT '0' NOT NULL, 1776 user_posts number(8) DEFAULT '0' NOT NULL, 1777 user_lang varchar2(30) DEFAULT '' , 1778 user_timezone number(5, 2) DEFAULT '0' NOT NULL, 1779 user_dst number(1) DEFAULT '0' NOT NULL, 1780 user_dateformat varchar2(90) DEFAULT 'd M Y H:i' NOT NULL, 1781 user_style number(8) DEFAULT '0' NOT NULL, 1782 user_rank number(8) DEFAULT '0' NOT NULL, 1783 user_colour varchar2(6) DEFAULT '' , 1784 user_new_privmsg number(4) DEFAULT '0' NOT NULL, 1785 user_unread_privmsg number(4) DEFAULT '0' NOT NULL, 1786 user_last_privmsg number(11) DEFAULT '0' NOT NULL, 1787 user_message_rules number(1) DEFAULT '0' NOT NULL, 1788 user_full_folder number(11) DEFAULT '-3' NOT NULL, 1789 user_emailtime number(11) DEFAULT '0' NOT NULL, 1790 user_topic_show_days number(4) DEFAULT '0' NOT NULL, 1791 user_topic_sortby_type varchar2(1) DEFAULT 't' NOT NULL, 1792 user_topic_sortby_dir varchar2(1) DEFAULT 'd' NOT NULL, 1793 user_post_show_days number(4) DEFAULT '0' NOT NULL, 1794 user_post_sortby_type varchar2(1) DEFAULT 't' NOT NULL, 1795 user_post_sortby_dir varchar2(1) DEFAULT 'a' NOT NULL, 1796 user_notify number(1) DEFAULT '0' NOT NULL, 1797 user_notify_pm number(1) DEFAULT '1' NOT NULL, 1798 user_notify_type number(4) DEFAULT '0' NOT NULL, 1799 user_allow_pm number(1) DEFAULT '1' NOT NULL, 1800 user_allow_viewonline number(1) DEFAULT '1' NOT NULL, 1801 user_allow_viewemail number(1) DEFAULT '1' NOT NULL, 1802 user_allow_massemail number(1) DEFAULT '1' NOT NULL, 1803 user_options number(11) DEFAULT '230271' NOT NULL, 1804 user_avatar varchar2(255) DEFAULT '' , 1805 user_avatar_type number(2) DEFAULT '0' NOT NULL, 1806 user_avatar_width number(4) DEFAULT '0' NOT NULL, 1807 user_avatar_height number(4) DEFAULT '0' NOT NULL, 1808 user_sig clob DEFAULT '' , 1809 user_sig_bbcode_uid varchar2(8) DEFAULT '' , 1810 user_sig_bbcode_bitfield varchar2(255) DEFAULT '' , 1811 user_from varchar2(300) DEFAULT '' , 1812 user_icq varchar2(15) DEFAULT '' , 1813 user_aim varchar2(765) DEFAULT '' , 1814 user_yim varchar2(765) DEFAULT '' , 1815 user_msnm varchar2(765) DEFAULT '' , 1816 user_jabber varchar2(765) DEFAULT '' , 1817 user_website varchar2(600) DEFAULT '' , 1818 user_occ clob DEFAULT '' , 1819 user_interests clob DEFAULT '' , 1820 user_actkey varchar2(32) DEFAULT '' , 1821 user_newpasswd varchar2(120) DEFAULT '' , 1822 user_form_salt varchar2(96) DEFAULT '' , 1823 user_new number(1) DEFAULT '1' NOT NULL, 1824 user_reminded number(4) DEFAULT '0' NOT NULL, 1825 user_reminded_time number(11) DEFAULT '0' NOT NULL, 1826 CONSTRAINT pk_phpbb_users PRIMARY KEY (user_id), 1827 CONSTRAINT u_phpbb_username_clean UNIQUE (username_clean) 1828 ) 1829 / 1830 1831 CREATE INDEX phpbb_users_user_birthday ON phpbb_users (user_birthday) 1832 / 1833 CREATE INDEX phpbb_users_user_email_hash ON phpbb_users (user_email_hash) 1834 / 1835 CREATE INDEX phpbb_users_user_type ON phpbb_users (user_type) 1836 / 1837 1838 CREATE SEQUENCE phpbb_users_seq 1839 / 1840 1841 CREATE OR REPLACE TRIGGER t_phpbb_users 1842 BEFORE INSERT ON phpbb_users 1843 FOR EACH ROW WHEN ( 1844 new.user_id IS NULL OR new.user_id = 0 1845 ) 1846 BEGIN 1847 SELECT phpbb_users_seq.nextval 1848 INTO :new.user_id 1849 FROM dual; 1850 END; 1851 / 1852 1853 1854 /* 1855 Table: 'phpbb_warnings' 1856 */ 1857 CREATE TABLE phpbb_warnings ( 1858 warning_id number(8) NOT NULL, 1859 user_id number(8) DEFAULT '0' NOT NULL, 1860 post_id number(8) DEFAULT '0' NOT NULL, 1861 log_id number(8) DEFAULT '0' NOT NULL, 1862 warning_time number(11) DEFAULT '0' NOT NULL, 1863 CONSTRAINT pk_phpbb_warnings PRIMARY KEY (warning_id) 1864 ) 1865 / 1866 1867 1868 CREATE SEQUENCE phpbb_warnings_seq 1869 / 1870 1871 CREATE OR REPLACE TRIGGER t_phpbb_warnings 1872 BEFORE INSERT ON phpbb_warnings 1873 FOR EACH ROW WHEN ( 1874 new.warning_id IS NULL OR new.warning_id = 0 1875 ) 1876 BEGIN 1877 SELECT phpbb_warnings_seq.nextval 1878 INTO :new.warning_id 1879 FROM dual; 1880 END; 1881 / 1882 1883 1884 /* 1885 Table: 'phpbb_words' 1886 */ 1887 CREATE TABLE phpbb_words ( 1888 word_id number(8) NOT NULL, 1889 word varchar2(765) DEFAULT '' , 1890 replacement varchar2(765) DEFAULT '' , 1891 CONSTRAINT pk_phpbb_words PRIMARY KEY (word_id) 1892 ) 1893 / 1894 1895 1896 CREATE SEQUENCE phpbb_words_seq 1897 / 1898 1899 CREATE OR REPLACE TRIGGER t_phpbb_words 1900 BEFORE INSERT ON phpbb_words 1901 FOR EACH ROW WHEN ( 1902 new.word_id IS NULL OR new.word_id = 0 1903 ) 1904 BEGIN 1905 SELECT phpbb_words_seq.nextval 1906 INTO :new.word_id 1907 FROM dual; 1908 END; 1909 / 1910 1911 1912 /* 1913 Table: 'phpbb_zebra' 1914 */ 1915 CREATE TABLE phpbb_zebra ( 1916 user_id number(8) DEFAULT '0' NOT NULL, 1917 zebra_id number(8) DEFAULT '0' NOT NULL, 1918 friend number(1) DEFAULT '0' NOT NULL, 1919 foe number(1) DEFAULT '0' NOT NULL, 1920 CONSTRAINT pk_phpbb_zebra PRIMARY KEY (user_id, zebra_id) 1921 ) 1922 / 1923 1924
title
Description
Body
title
Description
Body
title
Description
Body
title
Body
Generated: Wed Oct 2 15:03:47 2013 | Cross-referenced by PHPXref 0.7.1 |