install_2-1_postgresql.sql 128 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535
  1. #### ATTENTION: You do not need to run or use this file! The install.php script does everything for you!
  2. #### Install script for PostgreSQL 8.0.1
  3. #
  4. # Create PostgreSQL functions.
  5. # Some taken from http://www.xach.com/aolserver/mysql-functions.sql and http://pgfoundry.org/projects/mysqlcompat/.
  6. # IP Regex in inet_aton from http://www.mkyong.com/database/regular-expression-in-postgresql/.
  7. CREATE OR REPLACE FUNCTION FROM_UNIXTIME(integer) RETURNS timestamp AS
  8. 'SELECT timestamp ''epoch'' + $1 * interval ''1 second'' AS result'
  9. LANGUAGE 'sql';
  10. CREATE OR REPLACE FUNCTION IFNULL (text, text) RETURNS text AS
  11. 'SELECT COALESCE($1, $2) AS result'
  12. LANGUAGE 'sql';
  13. CREATE OR REPLACE FUNCTION IFNULL (int4, int4) RETURNS int4 AS
  14. 'SELECT COALESCE($1, $2) AS result'
  15. LANGUAGE 'sql';
  16. CREATE OR REPLACE FUNCTION IFNULL (int8, int8) RETURNS int8 AS
  17. 'SELECT COALESCE($1, $2) AS result'
  18. LANGUAGE 'sql';
  19. CREATE OR REPLACE FUNCTION IFNULL (character varying, character varying) RETURNS character varying AS
  20. 'SELECT COALESCE($1, $2) AS result'
  21. LANGUAGE 'sql';
  22. CREATE OR REPLACE FUNCTION IFNULL (character varying, boolean) RETURNS character varying AS
  23. 'SELECT COALESCE($1, CAST(CAST($2 AS int) AS varchar)) AS result'
  24. LANGUAGE 'sql';
  25. CREATE OR REPLACE FUNCTION IFNULL (int, boolean) RETURNS int AS
  26. 'SELECT COALESCE($1, CAST($2 AS int)) AS result'
  27. LANGUAGE 'sql';
  28. CREATE OR REPLACE FUNCTION INET_ATON(text) RETURNS bigint AS
  29. 'SELECT
  30. CASE WHEN
  31. $1 !~ ''^[0-9]?[0-9]?[0-9]?\.[0-9]?[0-9]?[0-9]?\.[0-9]?[0-9]?[0-9]?\.[0-9]?[0-9]?[0-9]?$'' THEN 0
  32. ELSE
  33. split_part($1, ''.'', 1)::int8 * (256 * 256 * 256) +
  34. split_part($1, ''.'', 2)::int8 * (256 * 256) +
  35. split_part($1, ''.'', 3)::int8 * 256 +
  36. split_part($1, ''.'', 4)::int8
  37. END AS result'
  38. LANGUAGE 'sql';
  39. CREATE OR REPLACE FUNCTION INET_NTOA(bigint) RETURNS text AS
  40. 'SELECT
  41. (($1 >> 24) & 255::int8) || ''.'' ||
  42. (($1 >> 16) & 255::int8) || ''.'' ||
  43. (($1 >> 8) & 255::int8) || ''.'' ||
  44. ($1 & 255::int8) AS result'
  45. LANGUAGE 'sql';
  46. CREATE OR REPLACE FUNCTION FIND_IN_SET(needle text, haystack text) RETURNS integer AS '
  47. SELECT i AS result
  48. FROM generate_series(1, array_upper(string_to_array($2,'',''), 1)) AS g(i)
  49. WHERE (string_to_array($2,'',''))[i] = $1
  50. UNION ALL
  51. SELECT 0
  52. LIMIT 1'
  53. LANGUAGE 'sql';
  54. CREATE OR REPLACE FUNCTION FIND_IN_SET(needle integer, haystack text) RETURNS integer AS '
  55. SELECT i AS result
  56. FROM generate_series(1, array_upper(string_to_array($2,'',''), 1)) AS g(i)
  57. WHERE (string_to_array($2,'',''))[i] = CAST($1 AS text)
  58. UNION ALL
  59. SELECT 0
  60. LIMIT 1'
  61. LANGUAGE 'sql';
  62. CREATE OR REPLACE FUNCTION FIND_IN_SET(needle smallint, haystack text) RETURNS integer AS '
  63. SELECT i AS result
  64. FROM generate_series(1, array_upper(string_to_array($2,'',''), 1)) AS g(i)
  65. WHERE (string_to_array($2,'',''))[i] = CAST($1 AS text)
  66. UNION ALL
  67. SELECT 0
  68. LIMIT 1'
  69. LANGUAGE 'sql';
  70. CREATE OR REPLACE FUNCTION LEFT (text, int4) RETURNS text AS
  71. 'SELECT SUBSTRING($1 FROM 0 FOR $2) AS result'
  72. LANGUAGE 'sql';
  73. CREATE OR REPLACE FUNCTION add_num_text (text, integer) RETURNS text AS
  74. 'SELECT CAST ((CAST($1 AS integer) + $2) AS text) AS result'
  75. LANGUAGE 'sql';
  76. CREATE OR REPLACE FUNCTION YEAR (timestamp) RETURNS integer AS
  77. 'SELECT CAST (EXTRACT(YEAR FROM $1) AS integer) AS result'
  78. LANGUAGE 'sql';
  79. CREATE OR REPLACE FUNCTION MONTH (timestamp) RETURNS integer AS
  80. 'SELECT CAST (EXTRACT(MONTH FROM $1) AS integer) AS result'
  81. LANGUAGE 'sql';
  82. CREATE OR REPLACE FUNCTION day(date) RETURNS integer AS
  83. 'SELECT EXTRACT(DAY FROM DATE($1))::integer AS result'
  84. LANGUAGE 'sql';
  85. CREATE OR REPLACE FUNCTION DAYOFMONTH (timestamp) RETURNS integer AS
  86. 'SELECT CAST (EXTRACT(DAY FROM $1) AS integer) AS result'
  87. LANGUAGE 'sql';
  88. CREATE OR REPLACE FUNCTION HOUR (timestamp) RETURNS integer AS
  89. 'SELECT CAST (EXTRACT(HOUR FROM $1) AS integer) AS result'
  90. LANGUAGE 'sql';
  91. CREATE OR REPLACE FUNCTION DATE_FORMAT (timestamp, text) RETURNS text AS
  92. 'SELECT
  93. REPLACE(
  94. REPLACE($2, ''%m'', to_char($1, ''MM'')),
  95. ''%d'', to_char($1, ''DD'')) AS result'
  96. LANGUAGE 'sql';
  97. CREATE OR REPLACE FUNCTION TO_DAYS (timestamp) RETURNS integer AS
  98. 'SELECT DATE_PART(''DAY'', $1 - ''0001-01-01bc'')::integer AS result'
  99. LANGUAGE 'sql';
  100. CREATE OR REPLACE FUNCTION CONCAT (text, text) RETURNS text AS
  101. 'SELECT $1 || $2 AS result'
  102. LANGUAGE 'sql';
  103. CREATE OR REPLACE FUNCTION INSTR (text, text) RETURNS integer AS
  104. 'SELECT POSITION($2 in $1) AS result'
  105. LANGUAGE 'sql';
  106. CREATE OR REPLACE FUNCTION bool_not_eq_int (boolean, integer) RETURNS boolean AS
  107. 'SELECT CAST($1 AS integer) != $2 AS result'
  108. LANGUAGE 'sql';
  109. #
  110. # Create PostgreSQL operators.
  111. #
  112. CREATE OPERATOR + (PROCEDURE = add_num_text, LEFTARG = text, RIGHTARG = integer);
  113. CREATE OPERATOR != (PROCEDURE = bool_not_eq_int, LEFTARG = boolean, RIGHTARG = integer);
  114. #
  115. # Sequence for table `admin_info_files`
  116. #
  117. CREATE SEQUENCE {$db_prefix}admin_info_files_seq START WITH 8;
  118. #
  119. # Table structure for table `admin_info_files`
  120. #
  121. CREATE TABLE {$db_prefix}admin_info_files (
  122. id_file smallint default nextval('{$db_prefix}admin_info_files_seq'),
  123. filename varchar(255) NOT NULL,
  124. path varchar(255) NOT NULL,
  125. parameters varchar(255) NOT NULL,
  126. data text NOT NULL,
  127. filetype varchar(255) NOT NULL,
  128. PRIMARY KEY (id_file)
  129. );
  130. #
  131. # Indexes for table `admin_info_files`
  132. #
  133. CREATE INDEX {$db_prefix}admin_info_files_filename ON {$db_prefix}admin_info_files (filename);
  134. #
  135. # Dumping data for table `admin_info_files`
  136. #
  137. INSERT INTO {$db_prefix}admin_info_files (id_file, filename, path, parameters, data, filetype) VALUES (1, 'current-version.js', '/smf/', 'version=%3$s', '', 'text/javascript');
  138. INSERT INTO {$db_prefix}admin_info_files (id_file, filename, path, parameters, data, filetype) VALUES (2, 'detailed-version.js', '/smf/', 'language=%1$s&version=%3$s', '', 'text/javascript');
  139. INSERT INTO {$db_prefix}admin_info_files (id_file, filename, path, parameters, data, filetype) VALUES (3, 'latest-news.js', '/smf/', 'language=%1$s&format=%2$s', '', 'text/javascript');
  140. INSERT INTO {$db_prefix}admin_info_files (id_file, filename, path, parameters, data, filetype) VALUES (4, 'latest-packages.js', '/smf/', 'language=%1$s&version=%3$s', '', 'text/javascript');
  141. INSERT INTO {$db_prefix}admin_info_files (id_file, filename, path, parameters, data, filetype) VALUES (5, 'latest-smileys.js', '/smf/', 'language=%1$s&version=%3$s', '', 'text/javascript');
  142. INSERT INTO {$db_prefix}admin_info_files (id_file, filename, path, parameters, data, filetype) VALUES (6, 'latest-support.js', '/smf/', 'language=%1$s&version=%3$s', '', 'text/javascript');
  143. INSERT INTO {$db_prefix}admin_info_files (id_file, filename, path, parameters, data, filetype) VALUES (7, 'latest-themes.js', '/smf/', 'language=%1$s&version=%3$s', '', 'text/javascript');
  144. # --------------------------------------------------------
  145. #
  146. # Table structure for table `approval_queue`
  147. #
  148. CREATE TABLE {$db_prefix}approval_queue (
  149. id_msg int NOT NULL default '0',
  150. id_attach int NOT NULL default '0',
  151. id_event smallint NOT NULL default '0'
  152. );
  153. #
  154. # Sequence for table `attachments`
  155. #
  156. CREATE SEQUENCE {$db_prefix}attachments_seq;
  157. #
  158. # Table structure for table `attachments`
  159. #
  160. CREATE TABLE {$db_prefix}attachments (
  161. id_attach int default nextval('{$db_prefix}attachments_seq'),
  162. id_thumb int NOT NULL default '0',
  163. id_msg int NOT NULL default '0',
  164. id_member int NOT NULL default '0',
  165. id_folder smallint NOT NULL default '1',
  166. attachment_type smallint NOT NULL default '0',
  167. filename varchar(255) NOT NULL,
  168. file_hash varchar(40) NOT NULL default '',
  169. fileext varchar(8) NOT NULL default '',
  170. size int NOT NULL default '0',
  171. downloads int NOT NULL default '0',
  172. width int NOT NULL default '0',
  173. height int NOT NULL default '0',
  174. mime_type varchar(20) NOT NULL default '',
  175. approved smallint NOT NULL default '1',
  176. PRIMARY KEY (id_attach)
  177. );
  178. #
  179. # Indexes for table `attachments`
  180. #
  181. CREATE UNIQUE INDEX {$db_prefix}attachments_id_member ON {$db_prefix}attachments (id_member, id_attach);
  182. CREATE INDEX {$db_prefix}attachments_id_msg ON {$db_prefix}attachments (id_msg);
  183. CREATE INDEX {$db_prefix}attachments_attachment_type ON {$db_prefix}attachments (attachment_type);
  184. #
  185. # Sequence for table `ban_groups`
  186. #
  187. CREATE SEQUENCE {$db_prefix}ban_groups_seq;
  188. #
  189. # Table structure for table `ban_groups`
  190. #
  191. CREATE TABLE {$db_prefix}ban_groups (
  192. id_ban_group int default nextval('{$db_prefix}ban_groups_seq'),
  193. name varchar(20) NOT NULL default '',
  194. ban_time int NOT NULL default '0',
  195. expire_time int,
  196. cannot_access smallint NOT NULL default '0',
  197. cannot_register smallint NOT NULL default '0',
  198. cannot_post smallint NOT NULL default '0',
  199. cannot_login smallint NOT NULL default '0',
  200. reason varchar(255) NOT NULL,
  201. notes text NOT NULL,
  202. PRIMARY KEY (id_ban_group)
  203. );
  204. #
  205. # Sequence for table `ban_items`
  206. #
  207. CREATE SEQUENCE {$db_prefix}ban_items_seq;
  208. #
  209. # Table structure for table `ban_items`
  210. #
  211. CREATE TABLE {$db_prefix}ban_items (
  212. id_ban int default nextval('{$db_prefix}ban_items_seq'),
  213. id_ban_group smallint NOT NULL default '0',
  214. ip_low1 smallint NOT NULL default '0',
  215. ip_high1 smallint NOT NULL default '0',
  216. ip_low2 smallint NOT NULL default '0',
  217. ip_high2 smallint NOT NULL default '0',
  218. ip_low3 smallint NOT NULL default '0',
  219. ip_high3 smallint NOT NULL default '0',
  220. ip_low4 smallint NOT NULL default '0',
  221. ip_high4 smallint NOT NULL default '0',
  222. ip_low5 smallint NOT NULL default '0',
  223. ip_high5 smallint NOT NULL default '0',
  224. ip_low6 smallint NOT NULL default '0',
  225. ip_high6 smallint NOT NULL default '0',
  226. ip_low7 smallint NOT NULL default '0',
  227. ip_high7 smallint NOT NULL default '0',
  228. ip_low8 smallint NOT NULL default '0',
  229. ip_high8 smallint NOT NULL default '0',
  230. hostname varchar(255) NOT NULL,
  231. email_address varchar(255) NOT NULL,
  232. id_member int NOT NULL default '0',
  233. hits int NOT NULL default '0',
  234. PRIMARY KEY (id_ban)
  235. );
  236. #
  237. # Indexes for table `ban_items`
  238. #
  239. CREATE INDEX {$db_prefix}ban_items_id_ban_group ON {$db_prefix}ban_items (id_ban_group);
  240. #
  241. # Table structure for table `board_permissions`
  242. #
  243. CREATE TABLE {$db_prefix}board_permissions (
  244. id_group smallint NOT NULL default '0',
  245. id_profile smallint NOT NULL default '0',
  246. permission varchar(30) NOT NULL default '',
  247. add_deny smallint NOT NULL default '1',
  248. PRIMARY KEY (id_group, id_profile, permission)
  249. );
  250. #
  251. # Dumping data for table `board_permissions`
  252. #
  253. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (-1, 1, 'poll_view');
  254. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 1, 'remove_own');
  255. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 1, 'lock_own');
  256. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 1, 'mark_any_notify');
  257. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 1, 'mark_notify');
  258. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 1, 'modify_own');
  259. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 1, 'poll_add_own');
  260. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 1, 'poll_edit_own');
  261. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 1, 'poll_lock_own');
  262. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 1, 'poll_post');
  263. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 1, 'poll_view');
  264. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 1, 'poll_vote');
  265. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 1, 'post_attachment');
  266. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 1, 'post_new');
  267. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 1, 'post_reply_any');
  268. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 1, 'post_reply_own');
  269. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 1, 'post_unapproved_topics');
  270. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 1, 'post_unapproved_replies_any');
  271. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 1, 'post_unapproved_replies_own');
  272. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 1, 'post_unapproved_attachments');
  273. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 1, 'delete_own');
  274. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 1, 'report_any');
  275. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 1, 'send_topic');
  276. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 1, 'view_attachments');
  277. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 1, 'moderate_board');
  278. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 1, 'post_new');
  279. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 1, 'post_reply_own');
  280. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 1, 'post_reply_any');
  281. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 1, 'post_unapproved_topics');
  282. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 1, 'post_unapproved_replies_any');
  283. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 1, 'post_unapproved_replies_own');
  284. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 1, 'post_unapproved_attachments');
  285. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 1, 'poll_post');
  286. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 1, 'poll_add_any');
  287. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 1, 'poll_remove_any');
  288. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 1, 'poll_view');
  289. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 1, 'poll_vote');
  290. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 1, 'poll_lock_any');
  291. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 1, 'poll_edit_any');
  292. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 1, 'report_any');
  293. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 1, 'lock_own');
  294. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 1, 'send_topic');
  295. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 1, 'mark_any_notify');
  296. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 1, 'mark_notify');
  297. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 1, 'delete_own');
  298. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 1, 'modify_own');
  299. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 1, 'make_sticky');
  300. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 1, 'lock_any');
  301. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 1, 'remove_any');
  302. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 1, 'move_any');
  303. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 1, 'merge_any');
  304. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 1, 'split_any');
  305. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 1, 'delete_any');
  306. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 1, 'modify_any');
  307. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 1, 'approve_posts');
  308. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 1, 'post_attachment');
  309. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 1, 'view_attachments');
  310. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 1, 'moderate_board');
  311. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 1, 'post_new');
  312. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 1, 'post_reply_own');
  313. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 1, 'post_reply_any');
  314. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 1, 'post_unapproved_topics');
  315. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 1, 'post_unapproved_replies_any');
  316. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 1, 'post_unapproved_replies_own');
  317. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 1, 'post_unapproved_attachments');
  318. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 1, 'poll_post');
  319. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 1, 'poll_add_any');
  320. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 1, 'poll_remove_any');
  321. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 1, 'poll_view');
  322. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 1, 'poll_vote');
  323. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 1, 'poll_lock_any');
  324. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 1, 'poll_edit_any');
  325. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 1, 'report_any');
  326. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 1, 'lock_own');
  327. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 1, 'send_topic');
  328. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 1, 'mark_any_notify');
  329. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 1, 'mark_notify');
  330. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 1, 'delete_own');
  331. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 1, 'modify_own');
  332. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 1, 'make_sticky');
  333. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 1, 'lock_any');
  334. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 1, 'remove_any');
  335. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 1, 'move_any');
  336. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 1, 'merge_any');
  337. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 1, 'split_any');
  338. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 1, 'delete_any');
  339. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 1, 'modify_any');
  340. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 1, 'approve_posts');
  341. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 1, 'post_attachment');
  342. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 1, 'view_attachments');
  343. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (-1, 2, 'poll_view');
  344. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 2, 'remove_own');
  345. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 2, 'lock_own');
  346. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 2, 'mark_any_notify');
  347. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 2, 'mark_notify');
  348. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 2, 'modify_own');
  349. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 2, 'poll_view');
  350. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 2, 'poll_vote');
  351. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 2, 'post_attachment');
  352. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 2, 'post_new');
  353. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 2, 'post_reply_any');
  354. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 2, 'post_reply_own');
  355. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 2, 'post_unapproved_topics');
  356. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 2, 'post_unapproved_replies_any');
  357. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 2, 'post_unapproved_replies_own');
  358. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 2, 'post_unapproved_attachments');
  359. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 2, 'delete_own');
  360. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 2, 'report_any');
  361. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 2, 'send_topic');
  362. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 2, 'view_attachments');
  363. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 2, 'moderate_board');
  364. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 2, 'post_new');
  365. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 2, 'post_reply_own');
  366. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 2, 'post_reply_any');
  367. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 2, 'post_unapproved_topics');
  368. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 2, 'post_unapproved_replies_any');
  369. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 2, 'post_unapproved_replies_own');
  370. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 2, 'post_unapproved_attachments');
  371. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 2, 'poll_post');
  372. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 2, 'poll_add_any');
  373. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 2, 'poll_remove_any');
  374. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 2, 'poll_view');
  375. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 2, 'poll_vote');
  376. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 2, 'poll_lock_any');
  377. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 2, 'poll_edit_any');
  378. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 2, 'report_any');
  379. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 2, 'lock_own');
  380. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 2, 'send_topic');
  381. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 2, 'mark_any_notify');
  382. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 2, 'mark_notify');
  383. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 2, 'delete_own');
  384. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 2, 'modify_own');
  385. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 2, 'make_sticky');
  386. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 2, 'lock_any');
  387. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 2, 'remove_any');
  388. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 2, 'move_any');
  389. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 2, 'merge_any');
  390. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 2, 'split_any');
  391. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 2, 'delete_any');
  392. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 2, 'modify_any');
  393. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 2, 'approve_posts');
  394. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 2, 'post_attachment');
  395. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 2, 'view_attachments');
  396. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 2, 'moderate_board');
  397. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 2, 'post_new');
  398. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 2, 'post_reply_own');
  399. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 2, 'post_reply_any');
  400. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 2, 'post_unapproved_topics');
  401. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 2, 'post_unapproved_replies_any');
  402. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 2, 'post_unapproved_replies_own');
  403. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 2, 'post_unapproved_attachments');
  404. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 2, 'poll_post');
  405. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 2, 'poll_add_any');
  406. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 2, 'poll_remove_any');
  407. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 2, 'poll_view');
  408. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 2, 'poll_vote');
  409. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 2, 'poll_lock_any');
  410. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 2, 'poll_edit_any');
  411. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 2, 'report_any');
  412. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 2, 'lock_own');
  413. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 2, 'send_topic');
  414. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 2, 'mark_any_notify');
  415. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 2, 'mark_notify');
  416. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 2, 'delete_own');
  417. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 2, 'modify_own');
  418. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 2, 'make_sticky');
  419. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 2, 'lock_any');
  420. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 2, 'remove_any');
  421. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 2, 'move_any');
  422. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 2, 'merge_any');
  423. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 2, 'split_any');
  424. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 2, 'delete_any');
  425. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 2, 'modify_any');
  426. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 2, 'approve_posts');
  427. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 2, 'post_attachment');
  428. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 2, 'view_attachments');
  429. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (-1, 3, 'poll_view');
  430. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 3, 'remove_own');
  431. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 3, 'lock_own');
  432. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 3, 'mark_any_notify');
  433. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 3, 'mark_notify');
  434. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 3, 'modify_own');
  435. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 3, 'poll_view');
  436. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 3, 'poll_vote');
  437. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 3, 'post_attachment');
  438. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 3, 'post_reply_any');
  439. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 3, 'post_reply_own');
  440. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 3, 'post_unapproved_replies_any');
  441. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 3, 'post_unapproved_replies_own');
  442. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 3, 'post_unapproved_attachments');
  443. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 3, 'delete_own');
  444. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 3, 'report_any');
  445. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 3, 'send_topic');
  446. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 3, 'view_attachments');
  447. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 3, 'moderate_board');
  448. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 3, 'post_new');
  449. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 3, 'post_reply_own');
  450. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 3, 'post_reply_any');
  451. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 3, 'post_unapproved_topics');
  452. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 3, 'post_unapproved_replies_any');
  453. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 3, 'post_unapproved_replies_own');
  454. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 3, 'post_unapproved_attachments');
  455. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 3, 'poll_post');
  456. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 3, 'poll_add_any');
  457. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 3, 'poll_remove_any');
  458. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 3, 'poll_view');
  459. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 3, 'poll_vote');
  460. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 3, 'poll_lock_any');
  461. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 3, 'poll_edit_any');
  462. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 3, 'report_any');
  463. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 3, 'lock_own');
  464. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 3, 'send_topic');
  465. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 3, 'mark_any_notify');
  466. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 3, 'mark_notify');
  467. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 3, 'delete_own');
  468. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 3, 'modify_own');
  469. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 3, 'make_sticky');
  470. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 3, 'lock_any');
  471. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 3, 'remove_any');
  472. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 3, 'move_any');
  473. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 3, 'merge_any');
  474. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 3, 'split_any');
  475. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 3, 'delete_any');
  476. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 3, 'modify_any');
  477. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 3, 'approve_posts');
  478. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 3, 'post_attachment');
  479. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 3, 'view_attachments');
  480. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 3, 'moderate_board');
  481. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 3, 'post_new');
  482. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 3, 'post_reply_own');
  483. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 3, 'post_reply_any');
  484. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 3, 'post_unapproved_topics');
  485. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 3, 'post_unapproved_replies_any');
  486. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 3, 'post_unapproved_replies_own');
  487. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 3, 'post_unapproved_attachments');
  488. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 3, 'poll_post');
  489. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 3, 'poll_add_any');
  490. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 3, 'poll_remove_any');
  491. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 3, 'poll_view');
  492. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 3, 'poll_vote');
  493. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 3, 'poll_lock_any');
  494. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 3, 'poll_edit_any');
  495. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 3, 'report_any');
  496. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 3, 'lock_own');
  497. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 3, 'send_topic');
  498. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 3, 'mark_any_notify');
  499. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 3, 'mark_notify');
  500. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 3, 'delete_own');
  501. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 3, 'modify_own');
  502. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 3, 'make_sticky');
  503. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 3, 'lock_any');
  504. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 3, 'remove_any');
  505. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 3, 'move_any');
  506. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 3, 'merge_any');
  507. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 3, 'split_any');
  508. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 3, 'delete_any');
  509. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 3, 'modify_any');
  510. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 3, 'approve_posts');
  511. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 3, 'post_attachment');
  512. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 3, 'view_attachments');
  513. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (-1, 4, 'poll_view');
  514. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 4, 'mark_any_notify');
  515. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 4, 'mark_notify');
  516. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 4, 'poll_view');
  517. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 4, 'poll_vote');
  518. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 4, 'report_any');
  519. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 4, 'send_topic');
  520. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (0, 4, 'view_attachments');
  521. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 4, 'moderate_board');
  522. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 4, 'post_new');
  523. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 4, 'post_reply_own');
  524. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 4, 'post_reply_any');
  525. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 4, 'post_unapproved_topics');
  526. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 4, 'post_unapproved_replies_any');
  527. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 4, 'post_unapproved_replies_own');
  528. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 4, 'post_unapproved_attachments');
  529. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 4, 'poll_post');
  530. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 4, 'poll_add_any');
  531. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 4, 'poll_remove_any');
  532. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 4, 'poll_view');
  533. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 4, 'poll_vote');
  534. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 4, 'poll_lock_any');
  535. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 4, 'poll_edit_any');
  536. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 4, 'report_any');
  537. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 4, 'lock_own');
  538. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 4, 'send_topic');
  539. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 4, 'mark_any_notify');
  540. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 4, 'mark_notify');
  541. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 4, 'delete_own');
  542. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 4, 'modify_own');
  543. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 4, 'make_sticky');
  544. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 4, 'lock_any');
  545. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 4, 'remove_any');
  546. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 4, 'move_any');
  547. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 4, 'merge_any');
  548. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 4, 'split_any');
  549. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 4, 'delete_any');
  550. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 4, 'modify_any');
  551. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 4, 'approve_posts');
  552. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 4, 'post_attachment');
  553. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (2, 4, 'view_attachments');
  554. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 4, 'moderate_board');
  555. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 4, 'post_new');
  556. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 4, 'post_reply_own');
  557. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 4, 'post_reply_any');
  558. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 4, 'post_unapproved_topics');
  559. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 4, 'post_unapproved_replies_any');
  560. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 4, 'post_unapproved_replies_own');
  561. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 4, 'post_unapproved_attachments');
  562. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 4, 'poll_post');
  563. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 4, 'poll_add_any');
  564. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 4, 'poll_remove_any');
  565. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 4, 'poll_view');
  566. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 4, 'poll_vote');
  567. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 4, 'poll_lock_any');
  568. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 4, 'poll_edit_any');
  569. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 4, 'report_any');
  570. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 4, 'lock_own');
  571. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 4, 'send_topic');
  572. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 4, 'mark_any_notify');
  573. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 4, 'mark_notify');
  574. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 4, 'delete_own');
  575. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 4, 'modify_own');
  576. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 4, 'make_sticky');
  577. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 4, 'lock_any');
  578. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 4, 'remove_any');
  579. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 4, 'move_any');
  580. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 4, 'merge_any');
  581. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 4, 'split_any');
  582. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 4, 'delete_any');
  583. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 4, 'modify_any');
  584. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 4, 'approve_posts');
  585. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 4, 'post_attachment');
  586. INSERT INTO {$db_prefix}board_permissions (id_group, id_profile, permission) VALUES (3, 4, 'view_attachments');
  587. # --------------------------------------------------------
  588. #
  589. # Sequence for table `boards`
  590. #
  591. CREATE SEQUENCE {$db_prefix}boards_seq START WITH 2;
  592. #
  593. # Table structure for table `boards`
  594. #
  595. CREATE TABLE {$db_prefix}boards (
  596. id_board smallint default nextval('{$db_prefix}boards_seq'),
  597. id_cat smallint NOT NULL default '0',
  598. child_level smallint NOT NULL default '0',
  599. id_parent smallint NOT NULL default '0',
  600. board_order smallint NOT NULL default '0',
  601. id_last_msg int NOT NULL default '0',
  602. id_msg_updated int NOT NULL default '0',
  603. member_groups varchar(255) NOT NULL default '-1,0',
  604. id_profile smallint NOT NULL default '1',
  605. name varchar(255) NOT NULL,
  606. description text NOT NULL,
  607. num_topics int NOT NULL default '0',
  608. num_posts int NOT NULL default '0',
  609. count_posts smallint NOT NULL default '0',
  610. id_theme smallint NOT NULL default '0',
  611. override_theme smallint NOT NULL default '0',
  612. unapproved_posts smallint NOT NULL default '0',
  613. unapproved_topics smallint NOT NULL default '0',
  614. redirect varchar(255) NOT NULL default '',
  615. PRIMARY KEY (id_board)
  616. );
  617. #
  618. # Indexes for table `ban_items`
  619. #
  620. CREATE UNIQUE INDEX {$db_prefix}boards_categories ON {$db_prefix}boards (id_cat, id_board);
  621. CREATE INDEX {$db_prefix}boards_id_parent ON {$db_prefix}boards (id_parent);
  622. CREATE INDEX {$db_prefix}boards_id_msg_updated ON {$db_prefix}boards (id_msg_updated);
  623. CREATE INDEX {$db_prefix}boards_member_groups ON {$db_prefix}boards (member_groups);
  624. #
  625. # Dumping data for table `boards`
  626. #
  627. INSERT INTO {$db_prefix}boards
  628. (id_board, id_cat, board_order, id_last_msg, id_msg_updated, name, description, num_topics, num_posts, member_groups)
  629. VALUES (1, 1, 1, 1, 1, '{$default_board_name}', '{$default_board_description}', 1, 1, '-1,0,2');
  630. # --------------------------------------------------------
  631. #
  632. # Sequence for table `calendar`
  633. #
  634. CREATE SEQUENCE {$db_prefix}calendar_seq;
  635. #
  636. # Table structure for table `calendar`
  637. #
  638. CREATE TABLE {$db_prefix}calendar (
  639. id_event smallint default nextval('{$db_prefix}calendar_seq'),
  640. start_date date NOT NULL default '0001-01-01',
  641. end_date date NOT NULL default '0001-01-01',
  642. id_board smallint NOT NULL default '0',
  643. id_topic int NOT NULL default '0',
  644. title varchar(255) NOT NULL default '',
  645. id_member int NOT NULL default '0',
  646. PRIMARY KEY (id_event)
  647. );
  648. #
  649. # Indexes for table `calendar`
  650. #
  651. CREATE INDEX {$db_prefix}calendar_start_date ON {$db_prefix}calendar (start_date);
  652. CREATE INDEX {$db_prefix}calendar_end_date ON {$db_prefix}calendar (end_date);
  653. CREATE INDEX {$db_prefix}calendar_topic ON {$db_prefix}calendar (id_topic, id_member);
  654. #
  655. # Sequence for table `calendar_holidays`
  656. #
  657. CREATE SEQUENCE {$db_prefix}calendar_holidays_seq;
  658. #
  659. # Table structure for table `calendar_holidays`
  660. #
  661. CREATE TABLE {$db_prefix}calendar_holidays (
  662. id_holiday smallint default nextval('{$db_prefix}calendar_holidays_seq'),
  663. event_date date NOT NULL default '0001-01-01',
  664. title varchar(255) NOT NULL default '',
  665. PRIMARY KEY (id_holiday)
  666. );
  667. #
  668. # Indexes for table `calendar_holidays`
  669. #
  670. CREATE INDEX {$db_prefix}calendar_holidays_event_date ON {$db_prefix}calendar_holidays (event_date);
  671. #
  672. # Dumping data for table `calendar_holidays`
  673. #
  674. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('New Year\'s', '0004-01-01');
  675. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Christmas', '0004-12-25');
  676. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Valentine\'s Day', '0004-02-14');
  677. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('St. Patrick\'s Day', '0004-03-17');
  678. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('April Fools', '0004-04-01');
  679. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Earth Day', '0004-04-22');
  680. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('United Nations Day', '0004-10-24');
  681. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Halloween', '0004-10-31');
  682. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Mother\'s Day', '2010-05-09');
  683. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Mother\'s Day', '2011-05-08');
  684. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Mother\'s Day', '2012-05-13');
  685. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Mother\'s Day', '2013-05-12');
  686. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Mother\'s Day', '2014-05-11');
  687. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Mother\'s Day', '2015-05-10');
  688. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Mother\'s Day', '2016-05-08');
  689. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Mother\'s Day', '2017-05-14');
  690. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Mother\'s Day', '2018-05-13');
  691. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Mother\'s Day', '2019-05-12');
  692. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Mother\'s Day', '2020-05-10');
  693. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Father\'s Day', '2010-06-20');
  694. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Father\'s Day', '2011-06-19');
  695. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Father\'s Day', '2012-06-17');
  696. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Father\'s Day', '2013-06-16');
  697. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Father\'s Day', '2014-06-15');
  698. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Father\'s Day', '2015-06-21');
  699. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Father\'s Day', '2016-06-19');
  700. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Father\'s Day', '2017-06-18');
  701. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Father\'s Day', '2018-06-17');
  702. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Father\'s Day', '2019-06-16');
  703. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Father\'s Day', '2020-06-21');
  704. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Summer Solstice', '2010-06-21');
  705. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Summer Solstice', '2011-06-21');
  706. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Summer Solstice', '2012-06-20');
  707. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Summer Solstice', '2013-06-21');
  708. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Summer Solstice', '2014-06-21');
  709. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Summer Solstice', '2015-06-21');
  710. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Summer Solstice', '2016-06-20');
  711. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Summer Solstice', '2017-06-20');
  712. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Summer Solstice', '2018-06-21');
  713. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Summer Solstice', '2019-06-21');
  714. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Summer Solstice', '2020-06-20');
  715. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Vernal Equinox', '2010-03-20');
  716. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Vernal Equinox', '2011-03-20');
  717. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Vernal Equinox', '2012-03-20');
  718. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Vernal Equinox', '2013-03-20');
  719. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Vernal Equinox', '2014-03-20');
  720. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Vernal Equinox', '2015-03-20');
  721. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Vernal Equinox', '2016-03-19');
  722. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Vernal Equinox', '2017-03-20');
  723. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Vernal Equinox', '2018-03-20');
  724. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Vernal Equinox', '2019-03-20');
  725. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Vernal Equinox', '2020-03-19');
  726. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Winter Solstice', '2010-12-21');
  727. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Winter Solstice', '2011-12-22');
  728. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Winter Solstice', '2012-12-21');
  729. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Winter Solstice', '2013-12-21');
  730. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Winter Solstice', '2014-12-21');
  731. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Winter Solstice', '2015-12-21');
  732. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Winter Solstice', '2016-12-21');
  733. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Winter Solstice', '2017-12-21');
  734. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Winter Solstice', '2018-12-21');
  735. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Winter Solstice', '2019-12-21');
  736. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Winter Solstice', '2020-12-21');
  737. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Autumnal Equinox', '2010-09-22');
  738. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Autumnal Equinox', '2011-09-23');
  739. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Autumnal Equinox', '2012-09-22');
  740. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Autumnal Equinox', '2013-09-22');
  741. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Autumnal Equinox', '2014-09-22');
  742. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Autumnal Equinox', '2015-09-23');
  743. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Autumnal Equinox', '2016-09-22');
  744. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Autumnal Equinox', '2017-09-22');
  745. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Autumnal Equinox', '2018-09-22');
  746. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Autumnal Equinox', '2019-09-23');
  747. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Autumnal Equinox', '2020-09-22');
  748. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Independence Day', '0004-07-04');
  749. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Cinco de Mayo', '0004-05-05');
  750. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Flag Day', '0004-06-14');
  751. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Veterans Day', '0004-11-11');
  752. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Groundhog Day', '0004-02-02');
  753. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Thanksgiving', '2010-11-25');
  754. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Thanksgiving', '2011-11-24');
  755. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Thanksgiving', '2012-11-22');
  756. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Thanksgiving', '2013-11-21');
  757. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Thanksgiving', '2014-11-20');
  758. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Thanksgiving', '2015-11-26');
  759. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Thanksgiving', '2016-11-24');
  760. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Thanksgiving', '2017-11-23');
  761. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Thanksgiving', '2018-11-22');
  762. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Thanksgiving', '2019-11-21');
  763. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Thanksgiving', '2020-11-26');
  764. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Memorial Day', '2010-05-31');
  765. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Memorial Day', '2011-05-30');
  766. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Memorial Day', '2012-05-28');
  767. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Memorial Day', '2013-05-27');
  768. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Memorial Day', '2014-05-26');
  769. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Memorial Day', '2015-05-25');
  770. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Memorial Day', '2016-05-30');
  771. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Memorial Day', '2017-05-29');
  772. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Memorial Day', '2018-05-28');
  773. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Memorial Day', '2019-05-27');
  774. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Memorial Day', '2020-05-25');
  775. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Labor Day', '2010-09-06');
  776. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Labor Day', '2011-09-05');
  777. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Labor Day', '2012-09-03');
  778. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Labor Day', '2013-09-09');
  779. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Labor Day', '2014-09-08');
  780. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Labor Day', '2015-09-07');
  781. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Labor Day', '2016-09-05');
  782. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Labor Day', '2017-09-04');
  783. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Labor Day', '2018-09-03');
  784. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Labor Day', '2019-09-09');
  785. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('Labor Day', '2020-09-07');
  786. INSERT INTO {$db_prefix}calendar_holidays (title, event_date) VALUES ('D-Day', '0004-06-06');
  787. # --------------------------------------------------------
  788. #
  789. # Sequence for table `categories`
  790. #
  791. CREATE SEQUENCE {$db_prefix}categories_seq START WITH 2;
  792. #
  793. # Table structure for table `categories`
  794. #
  795. CREATE TABLE {$db_prefix}categories (
  796. id_cat smallint default nextval('{$db_prefix}categories_seq'),
  797. cat_order smallint NOT NULL default '0',
  798. name varchar(255) NOT NULL,
  799. can_collapse smallint NOT NULL default '1',
  800. PRIMARY KEY (id_cat)
  801. );
  802. #
  803. # Dumping data for table `categories`
  804. #
  805. INSERT INTO {$db_prefix}categories
  806. VALUES (1, 0, '{$default_category_name}', 1);
  807. # --------------------------------------------------------
  808. #
  809. # Table structure for table `collapsed_categories`
  810. #
  811. CREATE TABLE {$db_prefix}collapsed_categories (
  812. id_cat smallint NOT NULL default '0',
  813. id_member int NOT NULL default '0',
  814. PRIMARY KEY (id_cat, id_member)
  815. );
  816. #
  817. # Sequence for table `custom_fields`
  818. #
  819. CREATE SEQUENCE {$db_prefix}custom_fields_seq;
  820. #
  821. # Table structure for table `custom_fields`
  822. #
  823. CREATE TABLE {$db_prefix}custom_fields (
  824. id_field smallint default nextval('{$db_prefix}custom_fields_seq'),
  825. col_name varchar(12) NOT NULL default '',
  826. field_name varchar(40) NOT NULL default '',
  827. field_desc varchar(255) NOT NULL,
  828. field_type varchar(8) NOT NULL default 'text',
  829. field_length smallint NOT NULL default '255',
  830. field_options text NOT NULL,
  831. mask varchar(255) NOT NULL,
  832. show_reg smallint NOT NULL default '0',
  833. show_display smallint NOT NULL default '0',
  834. show_profile varchar(20) NOT NULL default 'forumprofile',
  835. private smallint NOT NULL default '0',
  836. active smallint NOT NULL default '1',
  837. bbc smallint NOT NULL default '0',
  838. can_search smallint NOT NULL default '0',
  839. default_value varchar(255) NOT NULL,
  840. enclose text NOT NULL,
  841. placement smallint NOT NULL default '0',
  842. PRIMARY KEY (id_field)
  843. );
  844. #
  845. # Indexes for table `custom_fields`
  846. #
  847. CREATE UNIQUE INDEX {$db_prefix}custom_fields_col_name ON {$db_prefix}custom_fields (col_name);
  848. #
  849. # Table structure for table `group_moderators`
  850. #
  851. CREATE TABLE {$db_prefix}group_moderators (
  852. id_group smallint NOT NULL default '0',
  853. id_member int NOT NULL default '0',
  854. PRIMARY KEY (id_group, id_member)
  855. );
  856. #
  857. # Sequence for table `log_actions`
  858. #
  859. CREATE SEQUENCE {$db_prefix}log_actions_seq;
  860. #
  861. # Table structure for table `log_actions`
  862. #
  863. CREATE TABLE {$db_prefix}log_actions (
  864. id_action int default nextval('{$db_prefix}log_actions_seq'),
  865. id_log smallint NOT NULL default '1',
  866. log_time int NOT NULL default '0',
  867. id_member int NOT NULL default '0',
  868. ip char(16) NOT NULL default ' ',
  869. action varchar(30) NOT NULL default '',
  870. id_board smallint NOT NULL default '0',
  871. id_topic int NOT NULL default '0',
  872. id_msg int NOT NULL default '0',
  873. extra text NOT NULL,
  874. PRIMARY KEY (id_action)
  875. );
  876. #
  877. # Indexes for table `log_actions`
  878. #
  879. CREATE INDEX {$db_prefix}log_actions_log_time ON {$db_prefix}log_actions (log_time);
  880. CREATE INDEX {$db_prefix}log_actions_id_member ON {$db_prefix}log_actions (id_member);
  881. CREATE INDEX {$db_prefix}log_actions_id_board ON {$db_prefix}log_actions (id_board);
  882. CREATE INDEX {$db_prefix}log_actions_id_msg ON {$db_prefix}log_actions (id_msg);
  883. CREATE INDEX {$db_prefix}log_actions_id_log ON {$db_prefix}log_actions (id_log);
  884. #
  885. # Table structure for table `log_activity`
  886. #
  887. CREATE TABLE {$db_prefix}log_activity (
  888. date date NOT NULL default '0001-01-01',
  889. hits int NOT NULL default '0',
  890. topics smallint NOT NULL default '0',
  891. posts smallint NOT NULL default '0',
  892. registers smallint NOT NULL default '0',
  893. most_on smallint NOT NULL default '0',
  894. PRIMARY KEY (date)
  895. );
  896. #
  897. # Indexes for table `log_activity`
  898. #
  899. CREATE INDEX {$db_prefix}log_activity_most_on ON {$db_prefix}log_activity (most_on);
  900. #
  901. # Sequence for table `log_banned`
  902. #
  903. CREATE SEQUENCE {$db_prefix}log_banned_seq;
  904. #
  905. # Table structure for table `log_banned`
  906. #
  907. CREATE TABLE {$db_prefix}log_banned (
  908. id_ban_log int default nextval('{$db_prefix}log_banned_seq'),
  909. id_member int NOT NULL default '0',
  910. ip char(16) NOT NULL default ' ',
  911. email varchar(255) NOT NULL,
  912. log_time int NOT NULL default '0',
  913. PRIMARY KEY (id_ban_log)
  914. );
  915. #
  916. # Indexes for table `log_banned`
  917. #
  918. CREATE INDEX {$db_prefix}log_banned_log_time ON {$db_prefix}log_banned (log_time);
  919. #
  920. # Table structure for table `log_boards`
  921. #
  922. CREATE TABLE {$db_prefix}log_boards (
  923. id_member int NOT NULL default '0',
  924. id_board smallint NOT NULL default '0',
  925. id_msg int NOT NULL default '0',
  926. PRIMARY KEY (id_member, id_board)
  927. );
  928. #
  929. # Sequence for table `log_comments`
  930. #
  931. CREATE SEQUENCE {$db_prefix}log_comments_seq;
  932. #
  933. # Table structure for table `log_comments`
  934. #
  935. CREATE TABLE {$db_prefix}log_comments (
  936. id_comment int default nextval('{$db_prefix}log_comments_seq'),
  937. id_member int NOT NULL default '0',
  938. member_name varchar(80) NOT NULL default '',
  939. comment_type varchar(8) NOT NULL default 'warning',
  940. id_recipient int NOT NULL default '0',
  941. recipient_name varchar(255) NOT NULL,
  942. log_time int NOT NULL default '0',
  943. id_notice int NOT NULL default '0',
  944. counter smallint NOT NULL default '0',
  945. body text NOT NULL,
  946. PRIMARY KEY (id_comment)
  947. );
  948. #
  949. # Indexes for table `log_comments`
  950. #
  951. CREATE INDEX {$db_prefix}log_comments_id_recipient ON {$db_prefix}log_comments (id_recipient);
  952. CREATE INDEX {$db_prefix}log_comments_log_time ON {$db_prefix}log_comments (log_time);
  953. CREATE INDEX {$db_prefix}log_comments_comment_type ON {$db_prefix}log_comments (comment_type);
  954. #
  955. # Table structure for table `log_digest`
  956. #
  957. CREATE TABLE {$db_prefix}log_digest (
  958. id_topic int NOT NULL,
  959. id_msg int NOT NULL,
  960. note_type varchar(10) NOT NULL default 'post',
  961. daily smallint NOT NULL default '0',
  962. exclude int NOT NULL default '0'
  963. );
  964. #
  965. # Sequence for table `log_errors`
  966. #
  967. CREATE SEQUENCE {$db_prefix}log_errors_seq;
  968. #
  969. # Table structure for table `log_errors`
  970. #
  971. CREATE TABLE {$db_prefix}log_errors (
  972. id_error int default nextval('{$db_prefix}log_errors_seq'),
  973. log_time int NOT NULL default '0',
  974. id_member int NOT NULL default '0',
  975. ip varchar(16) NOT NULL default '',
  976. url text NOT NULL,
  977. message text NOT NULL,
  978. session char(32) NOT NULL default ' ',
  979. error_type varchar(15) NOT NULL default 'general',
  980. file varchar(255) NOT NULL,
  981. line int NOT NULL default '0',
  982. PRIMARY KEY (id_error)
  983. );
  984. #
  985. # Indexes for table `log_errors`
  986. #
  987. CREATE INDEX {$db_prefix}log_errors_log_time ON {$db_prefix}log_errors (log_time);
  988. CREATE INDEX {$db_prefix}log_errors_id_member ON {$db_prefix}log_errors (id_member);
  989. CREATE INDEX {$db_prefix}log_errors_ip ON {$db_prefix}log_errors (ip);
  990. #
  991. # Table structure for table `log_floodcontrol`
  992. #
  993. CREATE TABLE {$db_prefix}log_floodcontrol (
  994. ip char(16) NOT NULL default ' ',
  995. log_time int NOT NULL default '0',
  996. log_type varchar(8) NOT NULL default 'post',
  997. PRIMARY KEY (ip, log_type)
  998. );
  999. #
  1000. # Sequence for table `log_group_requests`
  1001. #
  1002. CREATE SEQUENCE {$db_prefix}log_group_requests_seq;
  1003. #
  1004. # Table structure for table `log_group_requests`
  1005. #
  1006. CREATE TABLE {$db_prefix}log_group_requests (
  1007. id_request int default nextval('{$db_prefix}log_group_requests_seq'),
  1008. id_member int NOT NULL default '0',
  1009. id_group smallint NOT NULL default '0',
  1010. time_applied int NOT NULL default '0',
  1011. reason text NOT NULL,
  1012. PRIMARY KEY (id_request)
  1013. );
  1014. #
  1015. # Indexes for table `log_group_requests`
  1016. #
  1017. CREATE UNIQUE INDEX {$db_prefix}log_group_requests_id_member ON {$db_prefix}log_group_requests (id_member, id_group);
  1018. #
  1019. # Table structure for table `log_karma`
  1020. #
  1021. CREATE TABLE {$db_prefix}log_karma (
  1022. id_target int NOT NULL default '0',
  1023. id_executor int NOT NULL default '0',
  1024. log_time int NOT NULL default '0',
  1025. action smallint NOT NULL default '0',
  1026. PRIMARY KEY (id_target, id_executor)
  1027. );
  1028. #
  1029. # Indexes for table `log_karma`
  1030. #
  1031. CREATE INDEX {$db_prefix}log_karma_log_time ON {$db_prefix}log_karma (log_time);
  1032. #
  1033. # Table structure for table `log_mark_read`
  1034. #
  1035. CREATE TABLE {$db_prefix}log_mark_read (
  1036. id_member int NOT NULL default '0',
  1037. id_board smallint NOT NULL default '0',
  1038. id_msg int NOT NULL default '0',
  1039. PRIMARY KEY (id_member, id_board)
  1040. );
  1041. #
  1042. # Sequence for table `log_member_notices`
  1043. #
  1044. CREATE SEQUENCE {$db_prefix}log_member_notices_seq;
  1045. #
  1046. # Table structure for table `log_member_notices`
  1047. #
  1048. CREATE TABLE {$db_prefix}log_member_notices (
  1049. id_notice int default nextval('{$db_prefix}log_member_notices_seq'),
  1050. subject varchar(255) NOT NULL,
  1051. body text NOT NULL,
  1052. PRIMARY KEY (id_notice)
  1053. );
  1054. #
  1055. # Table structure for table `log_notify`
  1056. #
  1057. CREATE TABLE {$db_prefix}log_notify (
  1058. id_member int NOT NULL default '0',
  1059. id_topic int NOT NULL default '0',
  1060. id_board smallint NOT NULL default '0',
  1061. sent smallint NOT NULL default '0',
  1062. PRIMARY KEY (id_member, id_topic, id_board)
  1063. );
  1064. #
  1065. # Indexes for table `log_notify`
  1066. #
  1067. CREATE INDEX {$db_prefix}log_notify_id_topic ON {$db_prefix}log_notify (id_topic, id_member);
  1068. #
  1069. # Table structure for table `log_online`
  1070. #
  1071. CREATE TABLE {$db_prefix}log_online (
  1072. session varchar(32) NOT NULL default '',
  1073. log_time int NOT NULL default '0',
  1074. id_member int NOT NULL default '0',
  1075. id_spider smallint NOT NULL default '0',
  1076. ip int8 NOT NULL default '0',
  1077. url text NOT NULL,
  1078. PRIMARY KEY (session)
  1079. );
  1080. #
  1081. # Indexes for table `log_online`
  1082. #
  1083. CREATE INDEX {$db_prefix}log_online_log_time ON {$db_prefix}log_online (log_time);
  1084. CREATE INDEX {$db_prefix}log_online_id_member ON {$db_prefix}log_online (id_member);
  1085. #
  1086. # Sequence for table `log_packages`
  1087. #
  1088. CREATE SEQUENCE {$db_prefix}log_packages_seq;
  1089. #
  1090. # Table structure for table `log_packages`
  1091. #
  1092. CREATE TABLE {$db_prefix}log_packages (
  1093. id_install int default nextval('{$db_prefix}log_packages_seq'),
  1094. filename varchar(255) NOT NULL,
  1095. package_id varchar(255) NOT NULL,
  1096. name varchar(255) NOT NULL,
  1097. version varchar(255) NOT NULL,
  1098. id_member_installed int NOT NULL default '0',
  1099. member_installed varchar(255) NOT NULL,
  1100. time_installed int NOT NULL default '0',
  1101. id_member_removed int NOT NULL default '0',
  1102. member_removed varchar(255) NOT NULL,
  1103. time_removed int NOT NULL default '0',
  1104. install_state smallint NOT NULL default '1',
  1105. failed_steps text NOT NULL,
  1106. themes_installed varchar(255) NOT NULL,
  1107. db_changes text NOT NULL,
  1108. credits varchar(255) NOT NULL,
  1109. PRIMARY KEY (id_install)
  1110. );
  1111. #
  1112. # Indexes for table `log_packages`
  1113. #
  1114. CREATE INDEX {$db_prefix}log_packages_filename ON {$db_prefix}log_packages (filename);
  1115. #
  1116. # Table structure for table `log_polls`
  1117. #
  1118. CREATE TABLE {$db_prefix}log_polls (
  1119. id_poll int NOT NULL default '0',
  1120. id_member int NOT NULL default '0',
  1121. id_choice smallint NOT NULL default '0'
  1122. );
  1123. #
  1124. # Indexes for table `log_polls`
  1125. #
  1126. CREATE INDEX {$db_prefix}log_polls_id_poll ON {$db_prefix}log_polls (id_poll, id_member, id_choice);
  1127. #
  1128. # Sequence for table `log_reported`
  1129. #
  1130. CREATE SEQUENCE {$db_prefix}log_reported_seq;
  1131. #
  1132. # Table structure for table `log_reported`
  1133. #
  1134. CREATE TABLE {$db_prefix}log_reported (
  1135. id_report int default nextval('{$db_prefix}log_reported_seq'),
  1136. id_msg int NOT NULL default '0',
  1137. id_topic int NOT NULL default '0',
  1138. id_board smallint NOT NULL default '0',
  1139. id_member int NOT NULL default '0',
  1140. membername varchar(255) NOT NULL,
  1141. subject varchar(255) NOT NULL,
  1142. body text NOT NULL,
  1143. time_started int NOT NULL default '0',
  1144. time_updated int NOT NULL default '0',
  1145. num_reports int NOT NULL default '0',
  1146. closed smallint NOT NULL default '0',
  1147. ignore_all smallint NOT NULL default '0',
  1148. PRIMARY KEY (id_report)
  1149. );
  1150. #
  1151. # Indexes for table `log_reported`
  1152. #
  1153. CREATE INDEX {$db_prefix}log_reported_id_member ON {$db_prefix}log_reported (id_member);
  1154. CREATE INDEX {$db_prefix}log_reported_id_topic ON {$db_prefix}log_reported (id_topic);
  1155. CREATE INDEX {$db_prefix}log_reported_closed ON {$db_prefix}log_reported (closed);
  1156. CREATE INDEX {$db_prefix}log_reported_time_started ON {$db_prefix}log_reported (time_started);
  1157. CREATE INDEX {$db_prefix}log_reported_id_msg ON {$db_prefix}log_reported (id_msg);
  1158. #
  1159. # Sequence for table `log_reported_comments`
  1160. #
  1161. CREATE SEQUENCE {$db_prefix}log_reported_comments_seq;
  1162. #
  1163. # Table structure for table `log_reported_comments`
  1164. #
  1165. CREATE TABLE {$db_prefix}log_reported_comments (
  1166. id_comment int default nextval('{$db_prefix}log_reported_comments_seq'),
  1167. id_report int NOT NULL default '0',
  1168. id_member int NOT NULL,
  1169. membername varchar(255) NOT NULL,
  1170. email_address varchar(255) NOT NULL,
  1171. member_ip varchar(255) NOT NULL,
  1172. comment varchar(255) NOT NULL,
  1173. time_sent int NOT NULL,
  1174. PRIMARY KEY (id_comment)
  1175. );
  1176. #
  1177. # Indexes for table `log_reported_comments`
  1178. #
  1179. CREATE INDEX {$db_prefix}log_reported_comments_id_report ON {$db_prefix}log_reported_comments (id_report);
  1180. CREATE INDEX {$db_prefix}log_reported_comments_id_member ON {$db_prefix}log_reported_comments (id_member);
  1181. CREATE INDEX {$db_prefix}log_reported_comments_time_sent ON {$db_prefix}log_reported_comments (time_sent);
  1182. #
  1183. # Sequence for table `log_scheduled_tasks`
  1184. #
  1185. CREATE SEQUENCE {$db_prefix}log_scheduled_tasks_seq;
  1186. #
  1187. # Table structure for table `log_scheduled_tasks`
  1188. #
  1189. CREATE TABLE {$db_prefix}log_scheduled_tasks (
  1190. id_log int default nextval('{$db_prefix}log_scheduled_tasks_seq'),
  1191. id_task smallint NOT NULL default '0',
  1192. time_run int NOT NULL default '0',
  1193. time_taken float NOT NULL default '0',
  1194. PRIMARY KEY (id_log)
  1195. );
  1196. #
  1197. # Table structure for table `log_search_messages`
  1198. #
  1199. CREATE TABLE {$db_prefix}log_search_messages (
  1200. id_search smallint NOT NULL default '0',
  1201. id_msg int NOT NULL default '0',
  1202. PRIMARY KEY (id_search, id_msg)
  1203. );
  1204. #
  1205. # Table structure for table `log_search_results`
  1206. #
  1207. CREATE TABLE {$db_prefix}log_search_results (
  1208. id_search smallint NOT NULL default '0',
  1209. id_topic int NOT NULL default '0',
  1210. id_msg int NOT NULL default '0',
  1211. relevance smallint NOT NULL default '0',
  1212. num_matches smallint NOT NULL default '0',
  1213. PRIMARY KEY (id_search, id_topic)
  1214. );
  1215. #
  1216. # Table structure for table `log_search_subjects`
  1217. #
  1218. CREATE TABLE {$db_prefix}log_search_subjects (
  1219. word varchar(20) NOT NULL default '',
  1220. id_topic int NOT NULL default '0',
  1221. PRIMARY KEY (word, id_topic)
  1222. );
  1223. #
  1224. # Indexes for table `log_search_subjects`
  1225. #
  1226. CREATE INDEX {$db_prefix}log_search_subjects_id_topic ON {$db_prefix}log_search_subjects (id_topic);
  1227. #
  1228. # Table structure for table `log_search_topics`
  1229. #
  1230. CREATE TABLE {$db_prefix}log_search_topics (
  1231. id_search smallint NOT NULL default '0',
  1232. id_topic int NOT NULL default '0',
  1233. PRIMARY KEY (id_search, id_topic)
  1234. );
  1235. #
  1236. # Sequence for table `log_spider_hits`
  1237. #
  1238. CREATE SEQUENCE {$db_prefix}log_spider_hits_seq;
  1239. #
  1240. # Table structure for table `log_spider_hits`
  1241. #
  1242. CREATE TABLE {$db_prefix}log_spider_hits (
  1243. id_hit int default nextval('{$db_prefix}log_spider_hits_seq'),
  1244. id_spider smallint NOT NULL default '0',
  1245. log_time int NOT NULL default '0',
  1246. url varchar(255) NOT NULL,
  1247. processed smallint NOT NULL default '0',
  1248. PRIMARY KEY (id_hit)
  1249. );
  1250. #
  1251. # Indexes for table `log_spider_hits`
  1252. #
  1253. CREATE INDEX {$db_prefix}log_spider_hits_id_spider ON {$db_prefix}log_spider_hits (id_spider);
  1254. CREATE INDEX {$db_prefix}log_spider_hits_log_time ON {$db_prefix}log_spider_hits (log_time);
  1255. CREATE INDEX {$db_prefix}log_spider_hits_processed ON {$db_prefix}log_spider_hits (processed);
  1256. #
  1257. # Table structure for table `log_spider_stats`
  1258. #
  1259. CREATE TABLE {$db_prefix}log_spider_stats (
  1260. id_spider smallint NOT NULL default '0',
  1261. page_hits smallint NOT NULL default '0',
  1262. last_seen int NOT NULL default '0',
  1263. stat_date date NOT NULL default '0001-01-01',
  1264. PRIMARY KEY (stat_date, id_spider)
  1265. );
  1266. #
  1267. # Sequence for table `log_subscribed`
  1268. #
  1269. CREATE SEQUENCE {$db_prefix}log_subscribed_seq;
  1270. #
  1271. # Table structure for table `log_subscribed`
  1272. #
  1273. CREATE TABLE {$db_prefix}log_subscribed (
  1274. id_sublog int default nextval('{$db_prefix}log_subscribed_seq'),
  1275. id_subscribe smallint NOT NULL default '0',
  1276. id_member int NOT NULL default '0',
  1277. old_id_group int NOT NULL default '0',
  1278. start_time int NOT NULL default '0',
  1279. end_time int NOT NULL default '0',
  1280. payments_pending smallint NOT NULL default '0',
  1281. status smallint NOT NULL default '0',
  1282. pending_details text NOT NULL default '',
  1283. reminder_sent smallint NOT NULL default '0',
  1284. vendor_ref varchar(255) NOT NULL default '',
  1285. PRIMARY KEY (id_sublog)
  1286. );
  1287. #
  1288. # Indexes for table `log_subscribed`
  1289. #
  1290. CREATE INDEX {$db_prefix}log_subscribed_id_subscribe ON {$db_prefix}log_subscribed (id_subscribe, id_member);
  1291. CREATE INDEX {$db_prefix}log_subscribed_end_time ON {$db_prefix}log_subscribed (end_time);
  1292. CREATE INDEX {$db_prefix}log_subscribed_reminder_sent ON {$db_prefix}log_subscribed (reminder_sent);
  1293. CREATE INDEX {$db_prefix}log_subscribed_payments_pending ON {$db_prefix}log_subscribed (payments_pending);
  1294. CREATE INDEX {$db_prefix}log_subscribed_status ON {$db_prefix}log_subscribed (status);
  1295. CREATE INDEX {$db_prefix}log_subscribed_id_member ON {$db_prefix}log_subscribed (id_member);
  1296. #
  1297. # Table structure for table `log_topics`
  1298. #
  1299. CREATE TABLE {$db_prefix}log_topics (
  1300. id_member int NOT NULL default '0',
  1301. id_topic int NOT NULL default '0',
  1302. id_msg int NOT NULL default '0',
  1303. PRIMARY KEY (id_member, id_topic)
  1304. );
  1305. #
  1306. # Indexes for table `log_topics`
  1307. #
  1308. CREATE INDEX {$db_prefix}log_topics_id_topic ON {$db_prefix}log_topics (id_topic);
  1309. #
  1310. # Sequence for table `mail_queue`
  1311. #
  1312. CREATE SEQUENCE {$db_prefix}mail_queue_seq;
  1313. #
  1314. # Table structure for table `mail_queue`
  1315. #
  1316. CREATE TABLE {$db_prefix}mail_queue (
  1317. id_mail int default nextval('{$db_prefix}mail_queue_seq'),
  1318. time_sent int NOT NULL default '0',
  1319. recipient varchar(255) NOT NULL,
  1320. body text NOT NULL,
  1321. subject varchar(255) NOT NULL,
  1322. headers text NOT NULL,
  1323. send_html smallint NOT NULL default '0',
  1324. priority smallint NOT NULL default '1',
  1325. private smallint NOT NULL default '0',
  1326. PRIMARY KEY (id_mail)
  1327. );
  1328. #
  1329. # Indexes for table `mail_queue`
  1330. #
  1331. CREATE INDEX {$db_prefix}mail_queue_time_sent ON {$db_prefix}mail_queue (time_sent);
  1332. CREATE INDEX {$db_prefix}mail_queue_mail_priority ON {$db_prefix}mail_queue (priority, id_mail);
  1333. #
  1334. # Sequence for table `membergroups`
  1335. #
  1336. CREATE SEQUENCE {$db_prefix}membergroups_seq START WITH 9;
  1337. #
  1338. # Table structure for table `membergroups`
  1339. #
  1340. CREATE TABLE {$db_prefix}membergroups (
  1341. id_group smallint default nextval('{$db_prefix}membergroups_seq'),
  1342. group_name varchar(80) NOT NULL default '',
  1343. description text NOT NULL,
  1344. online_color varchar(20) NOT NULL default '',
  1345. min_posts int NOT NULL default '-1',
  1346. max_messages smallint NOT NULL default '0',
  1347. stars varchar(255) NOT NULL,
  1348. group_type smallint NOT NULL default '0',
  1349. hidden smallint NOT NULL default '0',
  1350. id_parent smallint NOT NULL default '-2',
  1351. PRIMARY KEY (id_group)
  1352. );
  1353. #
  1354. # Indexes for table `membergroups`
  1355. #
  1356. CREATE INDEX {$db_prefix}membergroups_min_posts ON {$db_prefix}membergroups (min_posts);
  1357. #
  1358. # Dumping data for table `membergroups`
  1359. #
  1360. INSERT INTO {$db_prefix}membergroups (id_group, group_name, description, online_color, min_posts, stars, group_type) VALUES (1, '{$default_administrator_group}', '', '#FF0000', -1, '5#staradmin.png', 1);
  1361. INSERT INTO {$db_prefix}membergroups (id_group, group_name, description, online_color, min_posts, stars) VALUES (2, '{$default_global_moderator_group}', '', '#0000FF', -1, '5#stargmod.png');
  1362. INSERT INTO {$db_prefix}membergroups (id_group, group_name, description, online_color, min_posts, stars) VALUES (3, '{$default_moderator_group}', '', '', -1, '5#starmod.png');
  1363. INSERT INTO {$db_prefix}membergroups (id_group, group_name, description, online_color, min_posts, stars) VALUES (4, '{$default_newbie_group}', '', '', 0, '1#star.png');
  1364. INSERT INTO {$db_prefix}membergroups (id_group, group_name, description, online_color, min_posts, stars) VALUES (5, '{$default_junior_group}', '', '', 50, '2#star.png');
  1365. INSERT INTO {$db_prefix}membergroups (id_group, group_name, description, online_color, min_posts, stars) VALUES (6, '{$default_full_group}', '', '', 100, '3#star.png');
  1366. INSERT INTO {$db_prefix}membergroups (id_group, group_name, description, online_color, min_posts, stars) VALUES (7, '{$default_senior_group}', '', '', 250, '4#star.png');
  1367. INSERT INTO {$db_prefix}membergroups (id_group, group_name, description, online_color, min_posts, stars) VALUES (8, '{$default_hero_group}', '', '', 500, '5#star.png');
  1368. # --------------------------------------------------------
  1369. #
  1370. # Sequence for table `members`
  1371. #
  1372. CREATE SEQUENCE {$db_prefix}members_seq;
  1373. #
  1374. # Table structure for table `members`
  1375. #
  1376. CREATE TABLE {$db_prefix}members (
  1377. id_member int default nextval('{$db_prefix}members_seq'),
  1378. member_name varchar(80) NOT NULL default '',
  1379. date_registered int NOT NULL default '0',
  1380. posts int NOT NULL default '0',
  1381. id_group smallint NOT NULL default '0',
  1382. lngfile varchar(255) NOT NULL,
  1383. last_login int NOT NULL default '0',
  1384. real_name varchar(255) NOT NULL,
  1385. instant_messages smallint NOT NULL default 0,
  1386. unread_messages smallint NOT NULL default 0,
  1387. new_pm smallint NOT NULL default '0',
  1388. buddy_list text NOT NULL,
  1389. pm_ignore_list varchar(255) NOT NULL,
  1390. pm_prefs int NOT NULL default '0',
  1391. mod_prefs varchar(20) NOT NULL default '',
  1392. message_labels text NOT NULL,
  1393. passwd varchar(64) NOT NULL default '',
  1394. openid_uri text NOT NULL,
  1395. email_address varchar(255) NOT NULL,
  1396. personal_text varchar(255) NOT NULL,
  1397. gender smallint NOT NULL default '0',
  1398. birthdate date NOT NULL default '0001-01-01',
  1399. website_title varchar(255) NOT NULL,
  1400. website_url varchar(255) NOT NULL,
  1401. location varchar(255) NOT NULL,
  1402. icq varchar(255) NOT NULL,
  1403. aim varchar(255) NOT NULL default '',
  1404. yim varchar(32) NOT NULL default '',
  1405. msn varchar(255) NOT NULL,
  1406. hide_email smallint NOT NULL default '0',
  1407. show_online smallint NOT NULL default '1',
  1408. time_format varchar(80) NOT NULL default '',
  1409. signature text NOT NULL,
  1410. time_offset float NOT NULL default '0',
  1411. avatar varchar(255) NOT NULL,
  1412. pm_email_notify smallint NOT NULL default '0',
  1413. karma_bad smallint NOT NULL default '0',
  1414. karma_good smallint NOT NULL default '0',
  1415. usertitle varchar(255) NOT NULL,
  1416. notify_announcements smallint NOT NULL default '1',
  1417. notify_regularity smallint NOT NULL default '1',
  1418. notify_send_body smallint NOT NULL default '0',
  1419. notify_types smallint NOT NULL default '2',
  1420. member_ip varchar(255) NOT NULL,
  1421. member_ip2 varchar(255) NOT NULL,
  1422. secret_question varchar(255) NOT NULL,
  1423. secret_answer varchar(64) NOT NULL default '',
  1424. id_theme smallint NOT NULL default '0',
  1425. is_activated smallint NOT NULL default '1',
  1426. validation_code varchar(10) NOT NULL default '',
  1427. id_msg_last_visit int NOT NULL default '0',
  1428. additional_groups varchar(255) NOT NULL,
  1429. smiley_set varchar(48) NOT NULL default '',
  1430. id_post_group smallint NOT NULL default '0',
  1431. total_time_logged_in int NOT NULL default '0',
  1432. password_salt varchar(255) NOT NULL default '',
  1433. ignore_boards text NOT NULL,
  1434. warning smallint NOT NULL default '0',
  1435. passwd_flood varchar(12) NOT NULL default '',
  1436. pm_receive_from smallint NOT NULL default '1',
  1437. PRIMARY KEY (id_member)
  1438. );
  1439. #
  1440. # Indexes for table `members`
  1441. #
  1442. CREATE INDEX {$db_prefix}members_member_name ON {$db_prefix}members (member_name);
  1443. CREATE INDEX {$db_prefix}members_real_name ON {$db_prefix}members (real_name);
  1444. CREATE INDEX {$db_prefix}members_date_registered ON {$db_prefix}members (date_registered);
  1445. CREATE INDEX {$db_prefix}members_id_group ON {$db_prefix}members (id_group);
  1446. CREATE INDEX {$db_prefix}members_birthdate ON {$db_prefix}members (birthdate);
  1447. CREATE INDEX {$db_prefix}members_posts ON {$db_prefix}members (posts);
  1448. CREATE INDEX {$db_prefix}members_last_login ON {$db_prefix}members (last_login);
  1449. CREATE INDEX {$db_prefix}members_lngfile ON {$db_prefix}members (lngfile);
  1450. CREATE INDEX {$db_prefix}members_id_post_group ON {$db_prefix}members (id_post_group);
  1451. CREATE INDEX {$db_prefix}members_warning ON {$db_prefix}members (warning);
  1452. CREATE INDEX {$db_prefix}members_total_time_logged_in ON {$db_prefix}members (total_time_logged_in);
  1453. CREATE INDEX {$db_prefix}members_id_theme ON {$db_prefix}members (id_theme);
  1454. #
  1455. # Sequence for table `member_logins`
  1456. #
  1457. CREATE SEQUENCE {$db_prefix}member_logins_seq;
  1458. #
  1459. # Table structure for table `member_logins`
  1460. #
  1461. CREATE TABLE {$db_prefix}member_logins (
  1462. id_login int default nextval('{$db_prefix}member_logins_seq'),
  1463. id_member int NOT NULL default '0',
  1464. time int NOT NULL default '0',
  1465. ip varchar(255) NOT NULL default '0',
  1466. ip2 varchar(255) NOT NULL default '0',
  1467. PRIMARY KEY (id_login)
  1468. );
  1469. #
  1470. # Indexes for table `member_logins`
  1471. #
  1472. CREATE INDEX {$db_prefix}member_logins_id_member ON {$db_prefix}member_logins (id_member);
  1473. CREATE INDEX {$db_prefix}member_logins_time ON {$db_prefix}member_logins (time);
  1474. #
  1475. # Sequence for table `message_icons`
  1476. #
  1477. CREATE SEQUENCE {$db_prefix}message_icons_seq;
  1478. #
  1479. # Table structure for table `message_icons`
  1480. #
  1481. CREATE TABLE {$db_prefix}message_icons (
  1482. id_icon smallint default nextval('{$db_prefix}message_icons_seq'),
  1483. title varchar(80) NOT NULL default '',
  1484. filename varchar(80) NOT NULL default '',
  1485. id_board smallint NOT NULL default '0',
  1486. icon_order smallint NOT NULL default '0',
  1487. PRIMARY KEY (id_icon)
  1488. );
  1489. #
  1490. # Indexes for table `message_icons`
  1491. #
  1492. CREATE INDEX {$db_prefix}message_icons_id_board ON {$db_prefix}message_icons (id_board);
  1493. #
  1494. # Dumping data for table `message_icons`
  1495. #
  1496. # // !!! i18n
  1497. INSERT INTO {$db_prefix}message_icons (filename, title, icon_order) VALUES ('xx', 'Standard', '0');
  1498. INSERT INTO {$db_prefix}message_icons (filename, title, icon_order) VALUES ('thumbup', 'Thumb Up', '1');
  1499. INSERT INTO {$db_prefix}message_icons (filename, title, icon_order) VALUES ('thumbdown', 'Thumb Down', '2');
  1500. INSERT INTO {$db_prefix}message_icons (filename, title, icon_order) VALUES ('exclamation', 'Exclamation point', '3');
  1501. INSERT INTO {$db_prefix}message_icons (filename, title, icon_order) VALUES ('question', 'Question mark', '4');
  1502. INSERT INTO {$db_prefix}message_icons (filename, title, icon_order) VALUES ('lamp', 'Lamp', '5');
  1503. INSERT INTO {$db_prefix}message_icons (filename, title, icon_order) VALUES ('smiley', 'Smiley', '6');
  1504. INSERT INTO {$db_prefix}message_icons (filename, title, icon_order) VALUES ('angry', 'Angry', '7');
  1505. INSERT INTO {$db_prefix}message_icons (filename, title, icon_order) VALUES ('cheesy', 'Cheesy', '8');
  1506. INSERT INTO {$db_prefix}message_icons (filename, title, icon_order) VALUES ('grin', 'Grin', '9');
  1507. INSERT INTO {$db_prefix}message_icons (filename, title, icon_order) VALUES ('sad', 'Sad', '10');
  1508. INSERT INTO {$db_prefix}message_icons (filename, title, icon_order) VALUES ('wink', 'Wink', '11');
  1509. INSERT INTO {$db_prefix}message_icons (filename, title, icon_order) VALUES ('poll', 'Poll', '12');
  1510. # --------------------------------------------------------
  1511. #
  1512. # Sequence for table `messages`
  1513. #
  1514. CREATE SEQUENCE {$db_prefix}messages_seq START WITH 2;
  1515. #
  1516. # Table structure for table `messages`
  1517. #
  1518. CREATE TABLE {$db_prefix}messages (
  1519. id_msg int default nextval('{$db_prefix}messages_seq'),
  1520. id_topic int NOT NULL default '0',
  1521. id_board smallint NOT NULL default '0',
  1522. poster_time int NOT NULL default '0',
  1523. id_member int NOT NULL default '0',
  1524. id_msg_modified int NOT NULL default '0',
  1525. subject varchar(255) NOT NULL,
  1526. poster_name varchar(255) NOT NULL,
  1527. poster_email varchar(255) NOT NULL,
  1528. poster_ip varchar(255) NOT NULL,
  1529. smileys_enabled smallint NOT NULL default '1',
  1530. modified_time int NOT NULL default '0',
  1531. modified_name varchar(255) NOT NULL,
  1532. body text NOT NULL,
  1533. icon varchar(16) NOT NULL default 'xx',
  1534. approved smallint NOT NULL default '1',
  1535. PRIMARY KEY (id_msg)
  1536. );
  1537. #
  1538. # Indexes for table `messages`
  1539. #
  1540. CREATE UNIQUE INDEX {$db_prefix}messages_topic ON {$db_prefix}messages (id_topic, id_msg);
  1541. CREATE UNIQUE INDEX {$db_prefix}messages_id_board ON {$db_prefix}messages (id_board, id_msg);
  1542. CREATE UNIQUE INDEX {$db_prefix}messages_id_member ON {$db_prefix}messages (id_member, id_msg);
  1543. CREATE INDEX {$db_prefix}messages_approved ON {$db_prefix}messages (approved);
  1544. CREATE INDEX {$db_prefix}messages_ip_index ON {$db_prefix}messages (poster_ip, id_topic);
  1545. CREATE INDEX {$db_prefix}messages_participation ON {$db_prefix}messages (id_member, id_topic);
  1546. CREATE INDEX {$db_prefix}messages_show_posts ON {$db_prefix}messages (id_member, id_board);
  1547. CREATE INDEX {$db_prefix}messages_id_topic ON {$db_prefix}messages (id_topic);
  1548. CREATE INDEX {$db_prefix}messages_id_member_msg ON {$db_prefix}messages (id_member, approved, id_msg);
  1549. CREATE INDEX {$db_prefix}messages_current_topic ON {$db_prefix}messages (id_topic, id_msg, id_member, approved);
  1550. CREATE INDEX {$db_prefix}messages_related_ip ON {$db_prefix}messages (id_member, poster_ip, id_msg);
  1551. #
  1552. # Dumping data for table `messages`
  1553. #
  1554. INSERT INTO {$db_prefix}messages
  1555. (id_msg, id_msg_modified, id_topic, id_board, poster_time, subject, poster_name, poster_email, poster_ip, modified_name, body, icon)
  1556. VALUES (1, 1, 1, 1, {$current_time}, '{$default_topic_subject}', 'Simple Machines', '[email protected]', '127.0.0.1', '', '{$default_topic_message}', 'xx');
  1557. # --------------------------------------------------------
  1558. #
  1559. # Table structure for table `moderators`
  1560. #
  1561. CREATE TABLE {$db_prefix}moderators (
  1562. id_board smallint NOT NULL default '0',
  1563. id_member int NOT NULL default '0',
  1564. PRIMARY KEY (id_board, id_member)
  1565. );
  1566. #
  1567. # Table structure for table `openid_assoc`
  1568. #
  1569. CREATE TABLE {$db_prefix}openid_assoc (
  1570. server_url text NOT NULL,
  1571. handle varchar(255) NOT NULL,
  1572. secret text NOT NULL,
  1573. issued int NOT NULL default '0',
  1574. expires int NOT NULL default '0',
  1575. assoc_type varchar(64) NOT NULL,
  1576. PRIMARY KEY (server_url, handle)
  1577. );
  1578. #
  1579. # Indexes for table `openid_assoc`
  1580. #
  1581. CREATE INDEX {$db_prefix}openid_assoc_expires ON {$db_prefix}openid_assoc (expires);
  1582. #
  1583. # Sequence for table `package_servers`
  1584. #
  1585. CREATE SEQUENCE {$db_prefix}package_servers_seq;
  1586. #
  1587. # Table structure for table `package_servers`
  1588. #
  1589. CREATE TABLE {$db_prefix}package_servers (
  1590. id_server smallint default nextval('{$db_prefix}package_servers_seq'),
  1591. name varchar(255) NOT NULL,
  1592. url varchar(255) NOT NULL,
  1593. PRIMARY KEY (id_server)
  1594. );
  1595. #
  1596. # Dumping data for table `package_servers`
  1597. #
  1598. INSERT INTO {$db_prefix}package_servers
  1599. (name, url)
  1600. VALUES ('Simple Machines Third-party Mod Site', 'http://custom.simplemachines.org/packages/mods');
  1601. # --------------------------------------------------------
  1602. #
  1603. # Sequence for table `permission_profiles`
  1604. #
  1605. CREATE SEQUENCE {$db_prefix}permission_profiles_seq START WITH 5;
  1606. #
  1607. # Table structure for table `permission_profiles`
  1608. #
  1609. CREATE TABLE {$db_prefix}permission_profiles (
  1610. id_profile smallint default nextval('{$db_prefix}permission_profiles_seq'),
  1611. profile_name varchar(255) NOT NULL,
  1612. PRIMARY KEY (id_profile)
  1613. );
  1614. #
  1615. # Dumping data for table `permission_profiles`
  1616. #
  1617. INSERT INTO {$db_prefix}permission_profiles (id_profile, profile_name) VALUES (1, 'default');
  1618. INSERT INTO {$db_prefix}permission_profiles (id_profile, profile_name) VALUES (2, 'no_polls');
  1619. INSERT INTO {$db_prefix}permission_profiles (id_profile, profile_name) VALUES (3, 'reply_only');
  1620. INSERT INTO {$db_prefix}permission_profiles (id_profile, profile_name) VALUES (4, 'read_only');
  1621. # --------------------------------------------------------
  1622. #
  1623. # Table structure for table `permissions`
  1624. #
  1625. CREATE TABLE {$db_prefix}permissions (
  1626. id_group smallint NOT NULL default '0',
  1627. permission varchar(30) NOT NULL default '',
  1628. add_deny smallint NOT NULL default '1',
  1629. PRIMARY KEY (id_group, permission)
  1630. );
  1631. #
  1632. # Dumping data for table `permissions`
  1633. #
  1634. INSERT INTO {$db_prefix}permissions (id_group, permission) VALUES (-1, 'search_posts');
  1635. INSERT INTO {$db_prefix}permissions (id_group, permission) VALUES (-1, 'calendar_view');
  1636. INSERT INTO {$db_prefix}permissions (id_group, permission) VALUES (-1, 'view_stats');
  1637. INSERT INTO {$db_prefix}permissions (id_group, permission) VALUES (-1, 'profile_view_any');
  1638. INSERT INTO {$db_prefix}permissions (id_group, permission) VALUES (0, 'view_mlist');
  1639. INSERT INTO {$db_prefix}permissions (id_group, permission) VALUES (0, 'search_posts');
  1640. INSERT INTO {$db_prefix}permissions (id_group, permission) VALUES (0, 'profile_view_own');
  1641. INSERT INTO {$db_prefix}permissions (id_group, permission) VALUES (0, 'profile_view_any');
  1642. INSERT INTO {$db_prefix}permissions (id_group, permission) VALUES (0, 'pm_read');
  1643. INSERT INTO {$db_prefix}permissions (id_group, permission) VALUES (0, 'pm_send');
  1644. INSERT INTO {$db_prefix}permissions (id_group, permission) VALUES (0, 'calendar_view');
  1645. INSERT INTO {$db_prefix}permissions (id_group, permission) VALUES (0, 'view_stats');
  1646. INSERT INTO {$db_prefix}permissions (id_group, permission) VALUES (0, 'who_view');
  1647. INSERT INTO {$db_prefix}permissions (id_group, permission) VALUES (0, 'profile_identity_own');
  1648. INSERT INTO {$db_prefix}permissions (id_group, permission) VALUES (0, 'profile_extra_own');
  1649. INSERT INTO {$db_prefix}permissions (id_group, permission) VALUES (0, 'profile_remove_own');
  1650. INSERT INTO {$db_prefix}permissions (id_group, permission) VALUES (0, 'profile_server_avatar');
  1651. INSERT INTO {$db_prefix}permissions (id_group, permission) VALUES (0, 'profile_upload_avatar');
  1652. INSERT INTO {$db_prefix}permissions (id_group, permission) VALUES (0, 'profile_remote_avatar');
  1653. INSERT INTO {$db_prefix}permissions (id_group, permission) VALUES (0, 'karma_edit');
  1654. INSERT INTO {$db_prefix}permissions (id_group, permission) VALUES (2, 'view_mlist');
  1655. INSERT INTO {$db_prefix}permissions (id_group, permission) VALUES (2, 'search_posts');
  1656. INSERT INTO {$db_prefix}permissions (id_group, permission) VALUES (2, 'profile_view_own');
  1657. INSERT INTO {$db_prefix}permissions (id_group, permission) VALUES (2, 'profile_view_any');
  1658. INSERT INTO {$db_prefix}permissions (id_group, permission) VALUES (2, 'pm_read');
  1659. INSERT INTO {$db_prefix}permissions (id_group, permission) VALUES (2, 'pm_send');
  1660. INSERT INTO {$db_prefix}permissions (id_group, permission) VALUES (2, 'calendar_view');
  1661. INSERT INTO {$db_prefix}permissions (id_group, permission) VALUES (2, 'view_stats');
  1662. INSERT INTO {$db_prefix}permissions (id_group, permission) VALUES (2, 'who_view');
  1663. INSERT INTO {$db_prefix}permissions (id_group, permission) VALUES (2, 'profile_identity_own');
  1664. INSERT INTO {$db_prefix}permissions (id_group, permission) VALUES (2, 'profile_extra_own');
  1665. INSERT INTO {$db_prefix}permissions (id_group, permission) VALUES (2, 'profile_remove_own');
  1666. INSERT INTO {$db_prefix}permissions (id_group, permission) VALUES (2, 'profile_server_avatar');
  1667. INSERT INTO {$db_prefix}permissions (id_group, permission) VALUES (2, 'profile_upload_avatar');
  1668. INSERT INTO {$db_prefix}permissions (id_group, permission) VALUES (2, 'profile_remote_avatar');
  1669. INSERT INTO {$db_prefix}permissions (id_group, permission) VALUES (2, 'profile_title_own');
  1670. INSERT INTO {$db_prefix}permissions (id_group, permission) VALUES (2, 'calendar_post');
  1671. INSERT INTO {$db_prefix}permissions (id_group, permission) VALUES (2, 'calendar_edit_any');
  1672. INSERT INTO {$db_prefix}permissions (id_group, permission) VALUES (2, 'karma_edit');
  1673. INSERT INTO {$db_prefix}permissions (id_group, permission) VALUES (2, 'access_mod_center');
  1674. # --------------------------------------------------------
  1675. #
  1676. # Sequence for table `personal_messages`
  1677. #
  1678. CREATE SEQUENCE {$db_prefix}personal_messages_seq;
  1679. #
  1680. # Table structure for table `personal_messages`
  1681. #
  1682. CREATE TABLE {$db_prefix}personal_messages (
  1683. id_pm int default nextval('{$db_prefix}personal_messages_seq'),
  1684. id_pm_head int NOT NULL default '0',
  1685. id_member_from int NOT NULL default '0',
  1686. deleted_by_sender smallint NOT NULL default '0',
  1687. from_name varchar(255) NOT NULL,
  1688. msgtime int NOT NULL default '0',
  1689. subject varchar(255) NOT NULL,
  1690. body text NOT NULL,
  1691. PRIMARY KEY (id_pm)
  1692. );
  1693. #
  1694. # Indexes for table `personal_messages`
  1695. #
  1696. CREATE INDEX {$db_prefix}personal_messages_id_member ON {$db_prefix}personal_messages (id_member_from, deleted_by_sender);
  1697. CREATE INDEX {$db_prefix}personal_messages_msgtime ON {$db_prefix}personal_messages (msgtime);
  1698. CREATE INDEX {$db_prefix}personal_messages_id_pm_head ON {$db_prefix}personal_messages (id_pm_head);
  1699. #
  1700. # Table structure for table `pm_recipients`
  1701. #
  1702. CREATE TABLE {$db_prefix}pm_recipients (
  1703. id_pm int NOT NULL default '0',
  1704. id_member int NOT NULL default '0',
  1705. labels varchar(60) NOT NULL default '-1',
  1706. bcc smallint NOT NULL default '0',
  1707. is_read smallint NOT NULL default '0',
  1708. is_new smallint NOT NULL default '0',
  1709. deleted smallint NOT NULL default '0',
  1710. PRIMARY KEY (id_pm, id_member)
  1711. );
  1712. #
  1713. # Indexes for table `pm_recipients`
  1714. #
  1715. CREATE UNIQUE INDEX {$db_prefix}pm_recipients_id_member ON {$db_prefix}pm_recipients (id_member, deleted, id_pm);
  1716. #
  1717. # Sequence for table `pm_rules`
  1718. #
  1719. CREATE SEQUENCE {$db_prefix}pm_rules_seq;
  1720. #
  1721. # Table structure for table `pm_rules`
  1722. #
  1723. CREATE TABLE {$db_prefix}pm_rules (
  1724. id_rule int default nextval('{$db_prefix}pm_rules_seq'),
  1725. id_member int NOT NULL default '0',
  1726. rule_name varchar(60) NOT NULL,
  1727. criteria text NOT NULL,
  1728. actions text NOT NULL,
  1729. delete_pm smallint NOT NULL default '0',
  1730. is_or smallint NOT NULL default '0',
  1731. PRIMARY KEY (id_rule)
  1732. );
  1733. #
  1734. # Indexes for table `pm_rules`
  1735. #
  1736. CREATE INDEX {$db_prefix}pm_rules_id_member ON {$db_prefix}pm_rules (id_member);
  1737. CREATE INDEX {$db_prefix}pm_rules_delete_pm ON {$db_prefix}pm_rules (delete_pm);
  1738. #
  1739. # Sequence for table `polls`
  1740. #
  1741. CREATE SEQUENCE {$db_prefix}polls_seq;
  1742. #
  1743. # Table structure for table `polls`
  1744. #
  1745. CREATE TABLE {$db_prefix}polls (
  1746. id_poll int default nextval('{$db_prefix}polls_seq'),
  1747. question varchar(255) NOT NULL,
  1748. voting_locked smallint NOT NULL default '0',
  1749. max_votes smallint NOT NULL default '1',
  1750. expire_time int NOT NULL default '0',
  1751. hide_results smallint NOT NULL default '0',
  1752. change_vote smallint NOT NULL default '0',
  1753. guest_vote smallint NOT NULL default '0',
  1754. num_guest_voters int NOT NULL default '0',
  1755. reset_poll int NOT NULL default '0',
  1756. id_member int NOT NULL default '0',
  1757. poster_name varchar(255) NOT NULL,
  1758. PRIMARY KEY (id_poll)
  1759. );
  1760. #
  1761. # Table structure for table `poll_choices`
  1762. #
  1763. CREATE TABLE {$db_prefix}poll_choices (
  1764. id_poll int NOT NULL default '0',
  1765. id_choice smallint NOT NULL default '0',
  1766. label varchar(255) NOT NULL,
  1767. votes smallint NOT NULL default '0',
  1768. PRIMARY KEY (id_poll, id_choice)
  1769. );
  1770. #
  1771. # Sequence for table `scheduled_tasks`
  1772. #
  1773. CREATE SEQUENCE {$db_prefix}scheduled_tasks_seq START WITH 9;
  1774. #
  1775. # Table structure for table `scheduled_tasks`
  1776. #
  1777. CREATE TABLE {$db_prefix}scheduled_tasks (
  1778. id_task smallint default nextval('{$db_prefix}scheduled_tasks_seq'),
  1779. next_time int NOT NULL default '0',
  1780. time_offset int NOT NULL default '0',
  1781. time_regularity smallint NOT NULL default '0',
  1782. time_unit varchar(1) NOT NULL default 'h',
  1783. disabled smallint NOT NULL default '0',
  1784. task varchar(24) NOT NULL default '',
  1785. PRIMARY KEY (id_task)
  1786. );
  1787. #
  1788. # Indexes for table `scheduled_tasks`
  1789. #
  1790. CREATE INDEX {$db_prefix}scheduled_tasks_next_time ON {$db_prefix}scheduled_tasks (next_time);
  1791. CREATE INDEX {$db_prefix}scheduled_tasks_disabled ON {$db_prefix}scheduled_tasks (disabled);
  1792. CREATE UNIQUE INDEX {$db_prefix}scheduled_tasks_task ON {$db_prefix}scheduled_tasks (task);
  1793. #
  1794. # Dumping data for table `scheduled_tasks`
  1795. #
  1796. INSERT INTO {$db_prefix}scheduled_tasks (id_task, next_time, time_offset, time_regularity, time_unit, disabled, task) VALUES (1, 0, 0, 2, 'h', 0, 'approval_notification');
  1797. INSERT INTO {$db_prefix}scheduled_tasks (id_task, next_time, time_offset, time_regularity, time_unit, disabled, task) VALUES (2, 0, 0, 7, 'd', 0, 'auto_optimize');
  1798. INSERT INTO {$db_prefix}scheduled_tasks (id_task, next_time, time_offset, time_regularity, time_unit, disabled, task) VALUES (3, 0, 60, 1, 'd', 0, 'daily_maintenance');
  1799. INSERT INTO {$db_prefix}scheduled_tasks (id_task, next_time, time_offset, time_regularity, time_unit, disabled, task) VALUES (5, 0, 0, 1, 'd', 0, 'daily_digest');
  1800. INSERT INTO {$db_prefix}scheduled_tasks (id_task, next_time, time_offset, time_regularity, time_unit, disabled, task) VALUES (6, 0, 0, 1, 'w', 0, 'weekly_digest');
  1801. INSERT INTO {$db_prefix}scheduled_tasks (id_task, next_time, time_offset, time_regularity, time_unit, disabled, task) VALUES (7, 0, {$sched_task_offset}, 1, 'd', 0, 'fetchSMfiles');
  1802. INSERT INTO {$db_prefix}scheduled_tasks (id_task, next_time, time_offset, time_regularity, time_unit, disabled, task) VALUES (8, 0, 0, 1, 'd', 1, 'birthdayemails');
  1803. INSERT INTO {$db_prefix}scheduled_tasks (id_task, next_time, time_offset, time_regularity, time_unit, disabled, task) VALUES (9, 0, 0, 1, 'w', 0, 'weekly_maintenance');
  1804. INSERT INTO {$db_prefix}scheduled_tasks (id_task, next_time, time_offset, time_regularity, time_unit, disabled, task) VALUES (10, 0, 120, 1, 'd', 1, 'paid_subscriptions');
  1805. # --------------------------------------------------------
  1806. #
  1807. # Table structure for table `settings`
  1808. #
  1809. CREATE TABLE {$db_prefix}settings (
  1810. variable varchar(255) NOT NULL,
  1811. value text NOT NULL,
  1812. PRIMARY KEY (variable)
  1813. );
  1814. #
  1815. # Dumping data for table `settings`
  1816. #
  1817. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('smfVersion', '{$smf_version}');
  1818. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('news', '{$default_news}');
  1819. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('compactTopicPagesContiguous', '5');
  1820. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('compactTopicPagesEnable', '1');
  1821. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('enableStickyTopics', '1');
  1822. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('todayMod', '1');
  1823. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('karmaMode', '0');
  1824. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('karmaTimeRestrictAdmins', '1');
  1825. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('enablePreviousNext', '1');
  1826. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('pollMode', '1');
  1827. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('enableVBStyleLogin', '1');
  1828. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('enableCompressedOutput', '{$enableCompressedOutput}');
  1829. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('karmaWaitTime', '1');
  1830. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('karmaMinPosts', '0');
  1831. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('karmaLabel', '{$default_karmaLabel}');
  1832. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('karmaSmiteLabel', '{$default_karmaSmiteLabel}');
  1833. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('karmaApplaudLabel', '{$default_karmaApplaudLabel}');
  1834. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('attachmentSizeLimit', '128');
  1835. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('attachmentPostLimit', '192');
  1836. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('attachmentNumPerPostLimit', '4');
  1837. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('attachmentDirSizeLimit', '10240');
  1838. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('attachmentUploadDir', '{$boarddir}/attachments');
  1839. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('attachmentExtensions', 'doc,gif,jpg,mpg,pdf,png,txt,zip');
  1840. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('attachmentCheckExtensions', '0');
  1841. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('attachmentShowImages', '1');
  1842. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('attachmentEnable', '1');
  1843. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('attachmentEncryptFilenames', '1');
  1844. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('attachmentThumbnails', '1');
  1845. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('attachmentThumbWidth', '150');
  1846. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('attachmentThumbHeight', '150');
  1847. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('censorIgnoreCase', '1');
  1848. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('mostOnline', '1');
  1849. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('mostOnlineToday', '1');
  1850. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('mostDate', {$current_time});
  1851. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('allow_disableAnnounce', '1');
  1852. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('trackStats', '1');
  1853. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('userLanguage', '1');
  1854. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('titlesEnable', '1');
  1855. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('topicSummaryPosts', '15');
  1856. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('enableErrorLogging', '1');
  1857. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('max_image_width', '0');
  1858. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('max_image_height', '0');
  1859. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('onlineEnable', '0');
  1860. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('cal_enabled', '0');
  1861. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('cal_maxyear', '2020');
  1862. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('cal_minyear', '2008');
  1863. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('cal_daysaslink', '0');
  1864. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('cal_defaultboard', '');
  1865. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('cal_showholidays', '1');
  1866. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('cal_showbdays', '1');
  1867. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('cal_showevents', '1');
  1868. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('cal_showweeknum', '0');
  1869. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('cal_maxspan', '7');
  1870. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('smtp_host', '');
  1871. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('smtp_port', '25');
  1872. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('smtp_username', '');
  1873. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('smtp_password', '');
  1874. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('mail_type', '0');
  1875. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('timeLoadPageEnable', '0');
  1876. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('totalMembers', '0');
  1877. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('totalTopics', '1');
  1878. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('totalMessages', '1');
  1879. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('simpleSearch', '0');
  1880. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('censor_vulgar', '');
  1881. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('censor_proper', '');
  1882. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('enablePostHTML', '0');
  1883. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('theme_allow', '1');
  1884. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('theme_default', '1');
  1885. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('theme_guests', '1');
  1886. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('enableEmbeddedFlash', '0');
  1887. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('xmlnews_enable', '1');
  1888. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('xmlnews_maxlen', '255');
  1889. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('hotTopicPosts', '15');
  1890. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('hotTopicVeryPosts', '25');
  1891. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('registration_method', '0');
  1892. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('send_validation_onChange', '0');
  1893. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('send_welcomeEmail', '1');
  1894. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('allow_editDisplayName', '1');
  1895. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('allow_hideOnline', '1');
  1896. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('guest_hideContacts', '1');
  1897. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('spamWaitTime', '5');
  1898. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('pm_spam_settings', '10,5,20');
  1899. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('reserveWord', '0');
  1900. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('reserveCase', '1');
  1901. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('reserveUser', '1');
  1902. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('reserveName', '1');
  1903. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('reserveNames', '{$default_reserved_names}');
  1904. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('autoLinkUrls', '1');
  1905. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('banLastUpdated', '0');
  1906. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('smileys_dir', '{$boarddir}/Smileys');
  1907. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('smileys_url', '{$boardurl}/Smileys');
  1908. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('avatar_directory', '{$boarddir}/avatars');
  1909. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('avatar_url', '{$boardurl}/avatars');
  1910. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('avatar_max_height_external', '65');
  1911. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('avatar_max_width_external', '65');
  1912. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('avatar_action_too_large', 'option_html_resize');
  1913. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('avatar_max_height_upload', '65');
  1914. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('avatar_max_width_upload', '65');
  1915. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('avatar_resize_upload', '1');
  1916. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('avatar_download_png', '1');
  1917. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('failed_login_threshold', '3');
  1918. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('oldTopicDays', '120');
  1919. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('edit_wait_time', '90');
  1920. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('edit_disable_time', '0');
  1921. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('autoFixDatabase', '1');
  1922. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('allow_guestAccess', '1');
  1923. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('time_format', '{$default_time_format}');
  1924. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('number_format', '1234.00');
  1925. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('enableBBC', '1');
  1926. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('max_messageLength', '20000');
  1927. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('signature_settings', '1,300,0,0,0,0,0,0:');
  1928. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('autoOptMaxOnline', '0');
  1929. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('defaultMaxMessages', '15');
  1930. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('defaultMaxTopics', '20');
  1931. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('defaultMaxMembers', '30');
  1932. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('enableParticipation', '1');
  1933. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('recycle_enable', '0');
  1934. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('recycle_board', '0');
  1935. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('maxMsgID', '1');
  1936. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('enableAllMessages', '0');
  1937. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('fixLongWords', '0');
  1938. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('knownThemes', '1,2,3');
  1939. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('who_enabled', '1');
  1940. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('time_offset', '0');
  1941. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('cookieTime', '60');
  1942. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('lastActive', '15');
  1943. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('smiley_sets_known', 'default,aaron,akyhne');
  1944. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('smiley_sets_names', '{$default_smileyset_name}\n{$default_aaron_smileyset_name}\n{$default_akyhne_smileyset_name}');
  1945. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('smiley_sets_default', 'default');
  1946. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('cal_days_for_index', '7');
  1947. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('requireAgreement', '1');
  1948. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('unapprovedMembers', '0');
  1949. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('default_personal_text', '');
  1950. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('package_make_backups', '1');
  1951. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('databaseSession_enable', '{$databaseSession_enable}');
  1952. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('databaseSession_loose', '1');
  1953. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('databaseSession_lifetime', '2880');
  1954. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('search_cache_size', '50');
  1955. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('search_results_per_page', '30');
  1956. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('search_weight_frequency', '30');
  1957. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('search_weight_age', '25');
  1958. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('search_weight_length', '20');
  1959. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('search_weight_subject', '15');
  1960. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('search_weight_first_message', '10');
  1961. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('search_max_results', '1200');
  1962. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('search_floodcontrol_time', '5');
  1963. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('permission_enable_deny', '0');
  1964. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('permission_enable_postgroups', '0');
  1965. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('mail_next_send', '0');
  1966. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('mail_recent', '0000000000|0');
  1967. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('settings_updated', '0');
  1968. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('next_task_time', '1');
  1969. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('warning_settings', '1,20,0');
  1970. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('warning_watch', '10');
  1971. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('warning_moderate', '35');
  1972. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('warning_mute', '60');
  1973. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('admin_features', '');
  1974. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('last_mod_report_action', '0');
  1975. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('pruningOptions', '30,180,180,180,30,0');
  1976. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('cache_enable', '1');
  1977. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('reg_verification', '1');
  1978. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('visual_verification_type', '3');
  1979. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('enable_buddylist', '1');
  1980. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('birthday_email', 'happy_birthday');
  1981. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('dont_repeat_theme_core', '1');
  1982. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('dont_repeat_smileys_20', '1');
  1983. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('dont_repeat_buddylists', '1');
  1984. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('attachment_image_reencode', '1');
  1985. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('attachment_image_paranoid', '0');
  1986. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('attachment_thumb_png', '1');
  1987. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('avatar_reencode', '1');
  1988. INSERT INTO {$db_prefix}settings (variable, value) VALUES ('avatar_paranoid', '0');
  1989. # --------------------------------------------------------
  1990. #
  1991. # Table structure for table `sessions`
  1992. #
  1993. CREATE TABLE {$db_prefix}sessions (
  1994. session_id char(32) NOT NULL,
  1995. last_update int NOT NULL,
  1996. data text NOT NULL,
  1997. PRIMARY KEY (session_id)
  1998. );
  1999. #
  2000. # Sequence for table `smileys`
  2001. #
  2002. CREATE SEQUENCE {$db_prefix}smileys_seq;
  2003. #
  2004. # Table structure for table `smileys`
  2005. #
  2006. CREATE TABLE {$db_prefix}smileys (
  2007. id_smiley smallint default nextval('{$db_prefix}smileys_seq'),
  2008. code varchar(30) NOT NULL default '',
  2009. filename varchar(48) NOT NULL default '',
  2010. description varchar(80) NOT NULL default '',
  2011. smiley_row smallint NOT NULL default '0',
  2012. smiley_order smallint NOT NULL default '0',
  2013. hidden smallint NOT NULL default '0',
  2014. PRIMARY KEY (id_smiley)
  2015. );
  2016. #
  2017. # Dumping data for table `smileys`
  2018. #
  2019. INSERT INTO {$db_prefix}smileys (code, filename, description, smiley_order, hidden) VALUES (':)', 'smiley.gif', '{$default_smiley_smiley}', 0, 0);
  2020. INSERT INTO {$db_prefix}smileys (code, filename, description, smiley_order, hidden) VALUES (';)', 'wink.gif', '{$default_wink_smiley}', 1, 0);
  2021. INSERT INTO {$db_prefix}smileys (code, filename, description, smiley_order, hidden) VALUES (':D', 'cheesy.gif', '{$default_cheesy_smiley}', 2, 0);
  2022. INSERT INTO {$db_prefix}smileys (code, filename, description, smiley_order, hidden) VALUES (';D', 'grin.gif', '{$default_grin_smiley}', 3, 0);
  2023. INSERT INTO {$db_prefix}smileys (code, filename, description, smiley_order, hidden) VALUES ('>:(', 'angry.gif', '{$default_angry_smiley}', 4, 0);
  2024. INSERT INTO {$db_prefix}smileys (code, filename, description, smiley_order, hidden) VALUES (':(', 'sad.gif', '{$default_sad_smiley}', 5, 0);
  2025. INSERT INTO {$db_prefix}smileys (code, filename, description, smiley_order, hidden) VALUES (':o', 'shocked.gif', '{$default_shocked_smiley}', 6, 0);
  2026. INSERT INTO {$db_prefix}smileys (code, filename, description, smiley_order, hidden) VALUES ('8)', 'cool.gif', '{$default_cool_smiley}', 7, 0);
  2027. INSERT INTO {$db_prefix}smileys (code, filename, description, smiley_order, hidden) VALUES ('???', 'huh.gif', '{$default_huh_smiley}', 8, 0);
  2028. INSERT INTO {$db_prefix}smileys (code, filename, description, smiley_order, hidden) VALUES ('::)', 'rolleyes.gif', '{$default_roll_eyes_smiley}', 9, 0);
  2029. INSERT INTO {$db_prefix}smileys (code, filename, description, smiley_order, hidden) VALUES (':P', 'tongue.gif', '{$default_tongue_smiley}', 10, 0);
  2030. INSERT INTO {$db_prefix}smileys (code, filename, description, smiley_order, hidden) VALUES (':-[', 'embarrassed.gif', '{$default_embarrassed_smiley}', 11, 0);
  2031. INSERT INTO {$db_prefix}smileys (code, filename, description, smiley_order, hidden) VALUES (':-X', 'lipsrsealed.gif', '{$default_lips_sealed_smiley}', 12, 0);
  2032. INSERT INTO {$db_prefix}smileys (code, filename, description, smiley_order, hidden) VALUES (':-\\', 'undecided.gif', '{$default_undecided_smiley}', 13, 0);
  2033. INSERT INTO {$db_prefix}smileys (code, filename, description, smiley_order, hidden) VALUES (':-*', 'kiss.gif', '{$default_kiss_smiley}', 14, 0);
  2034. INSERT INTO {$db_prefix}smileys (code, filename, description, smiley_order, hidden) VALUES (':\'(', 'cry.gif', '{$default_cry_smiley}', 15, 0);
  2035. INSERT INTO {$db_prefix}smileys (code, filename, description, smiley_order, hidden) VALUES ('>:D', 'evil.gif', '{$default_evil_smiley}', 16, 1);
  2036. INSERT INTO {$db_prefix}smileys (code, filename, description, smiley_order, hidden) VALUES ('^-^', 'azn.gif', '{$default_azn_smiley}', 17, 1);
  2037. INSERT INTO {$db_prefix}smileys (code, filename, description, smiley_order, hidden) VALUES ('O0', 'afro.gif', '{$default_afro_smiley}', 18, 1);
  2038. INSERT INTO {$db_prefix}smileys (code, filename, description, smiley_order, hidden) VALUES (':))', 'laugh.gif', '{$default_laugh_smiley}', 19, 1);
  2039. INSERT INTO {$db_prefix}smileys (code, filename, description, smiley_order, hidden) VALUES ('C:-)', 'police.gif', '{$default_police_smiley}', 20, 1);
  2040. INSERT INTO {$db_prefix}smileys (code, filename, description, smiley_order, hidden) VALUES ('O:-)', 'angel.gif', '{$default_angel_smiley}', 21, 1);
  2041. # --------------------------------------------------------
  2042. #
  2043. # Sequence for table `spiders`
  2044. #
  2045. CREATE SEQUENCE {$db_prefix}spiders_seq;
  2046. #
  2047. # Table structure for table `spiders`
  2048. #
  2049. CREATE TABLE {$db_prefix}spiders (
  2050. id_spider smallint NOT NULL default nextval('{$db_prefix}spiders_seq'),
  2051. spider_name varchar(255) NOT NULL,
  2052. user_agent varchar(255) NOT NULL,
  2053. ip_info varchar(255) NOT NULL,
  2054. PRIMARY KEY (id_spider)
  2055. );
  2056. #
  2057. # Dumping data for table `spiders`
  2058. #
  2059. INSERT INTO {$db_prefix}spiders (id_spider, spider_name, user_agent, ip_info) VALUES (1, 'Google', 'googlebot', '');
  2060. INSERT INTO {$db_prefix}spiders (id_spider, spider_name, user_agent, ip_info) VALUES (2, 'Yahoo!', 'slurp', '');
  2061. INSERT INTO {$db_prefix}spiders (id_spider, spider_name, user_agent, ip_info) VALUES (3, 'MSN', 'msnbot', '');
  2062. INSERT INTO {$db_prefix}spiders (id_spider, spider_name, user_agent, ip_info) VALUES (4, 'Google (Mobile)', 'Googlebot-Mobile', '');
  2063. INSERT INTO {$db_prefix}spiders (id_spider, spider_name, user_agent, ip_info) VALUES (5, 'Google (Image)', 'Googlebot-Image', '');
  2064. INSERT INTO {$db_prefix}spiders (id_spider, spider_name, user_agent, ip_info) VALUES (6, 'Google (AdSense)', 'Mediapartners-Google', '');
  2065. INSERT INTO {$db_prefix}spiders (id_spider, spider_name, user_agent, ip_info) VALUES (7, 'Google (Adwords)', 'AdsBot-Google', '');
  2066. INSERT INTO {$db_prefix}spiders (id_spider, spider_name, user_agent, ip_info) VALUES (8, 'Yahoo! (Mobile)', 'YahooSeeker/M1A1-R2D2', '');
  2067. INSERT INTO {$db_prefix}spiders (id_spider, spider_name, user_agent, ip_info) VALUES (9, 'Yahoo! (Image)', 'Yahoo-MMCrawler', '');
  2068. INSERT INTO {$db_prefix}spiders (id_spider, spider_name, user_agent, ip_info) VALUES (10, 'MSN (Mobile)', 'MSNBOT_Mobile', '');
  2069. INSERT INTO {$db_prefix}spiders (id_spider, spider_name, user_agent, ip_info) VALUES (11, 'MSN (Media)', 'msnbot-media', '');
  2070. INSERT INTO {$db_prefix}spiders (id_spider, spider_name, user_agent, ip_info) VALUES (12, 'Cuil', 'twiceler', '');
  2071. INSERT INTO {$db_prefix}spiders (id_spider, spider_name, user_agent, ip_info) VALUES (13, 'Ask', 'Teoma', '');
  2072. INSERT INTO {$db_prefix}spiders (id_spider, spider_name, user_agent, ip_info) VALUES (14, 'Baidu', 'Baiduspider', '');
  2073. INSERT INTO {$db_prefix}spiders (id_spider, spider_name, user_agent, ip_info) VALUES (15, 'Gigablast', 'Gigabot', '');
  2074. INSERT INTO {$db_prefix}spiders (id_spider, spider_name, user_agent, ip_info) VALUES (16, 'InternetArchive', 'ia_archiver-web.archive.org', '');
  2075. INSERT INTO {$db_prefix}spiders (id_spider, spider_name, user_agent, ip_info) VALUES (17, 'Alexa', 'ia_archiver', '');
  2076. INSERT INTO {$db_prefix}spiders (id_spider, spider_name, user_agent, ip_info) VALUES (18, 'Omgili', 'omgilibot', '');
  2077. INSERT INTO {$db_prefix}spiders (id_spider, spider_name, user_agent, ip_info) VALUES (19, 'EntireWeb', 'Speedy Spider', '');
  2078. #
  2079. # Sequence for table `subscriptions`
  2080. #
  2081. CREATE SEQUENCE {$db_prefix}subscriptions_seq;
  2082. #
  2083. # Table structure for table `subscriptions`
  2084. #
  2085. CREATE TABLE {$db_prefix}subscriptions(
  2086. id_subscribe smallint NOT NULL default nextval('{$db_prefix}subscriptions_seq'),
  2087. name varchar(60) NOT NULL,
  2088. description varchar(255) NOT NULL,
  2089. cost text NOT NULL,
  2090. length varchar(6) NOT NULL,
  2091. id_group int NOT NULL default '0',
  2092. add_groups varchar(40) NOT NULL,
  2093. active smallint NOT NULL default '1',
  2094. repeatable smallint NOT NULL default '0',
  2095. allow_partial smallint NOT NULL default '0',
  2096. reminder smallint NOT NULL default '0',
  2097. email_complete text NOT NULL,
  2098. PRIMARY KEY (id_subscribe)
  2099. );
  2100. #
  2101. # Indexes for table `subscriptions`
  2102. #
  2103. CREATE INDEX {$db_prefix}subscriptions_active ON {$db_prefix}subscriptions (active);
  2104. #
  2105. # Table structure for table `themes`
  2106. #
  2107. CREATE TABLE {$db_prefix}themes (
  2108. id_member int NOT NULL default '0',
  2109. id_theme smallint NOT NULL default '1',
  2110. variable varchar(255) NOT NULL,
  2111. value text NOT NULL,
  2112. PRIMARY KEY (id_theme, id_member, variable)
  2113. );
  2114. #
  2115. # Indexes for table `themes`
  2116. #
  2117. CREATE INDEX {$db_prefix}themes_id_member ON {$db_prefix}themes (id_member);
  2118. #
  2119. # Dumping data for table `themes`
  2120. #
  2121. INSERT INTO {$db_prefix}themes (id_theme, variable, value) VALUES (1, 'name', '{$default_theme_name}');
  2122. INSERT INTO {$db_prefix}themes (id_theme, variable, value) VALUES (1, 'theme_url', '{$boardurl}/Themes/default');
  2123. INSERT INTO {$db_prefix}themes (id_theme, variable, value) VALUES (1, 'images_url', '{$boardurl}/Themes/default/images');
  2124. INSERT INTO {$db_prefix}themes (id_theme, variable, value) VALUES (1, 'theme_dir', '{$boarddir}/Themes/default');
  2125. INSERT INTO {$db_prefix}themes (id_theme, variable, value) VALUES (1, 'show_bbc', '1');
  2126. INSERT INTO {$db_prefix}themes (id_theme, variable, value) VALUES (1, 'show_latest_member', '1');
  2127. INSERT INTO {$db_prefix}themes (id_theme, variable, value) VALUES (1, 'show_modify', '1');
  2128. INSERT INTO {$db_prefix}themes (id_theme, variable, value) VALUES (1, 'show_user_images', '1');
  2129. INSERT INTO {$db_prefix}themes (id_theme, variable, value) VALUES (1, 'show_blurb', '1');
  2130. INSERT INTO {$db_prefix}themes (id_theme, variable, value) VALUES (1, 'show_gender', '0');
  2131. INSERT INTO {$db_prefix}themes (id_theme, variable, value) VALUES (1, 'show_newsfader', '0');
  2132. INSERT INTO {$db_prefix}themes (id_theme, variable, value) VALUES (1, 'number_recent_posts', '0');
  2133. INSERT INTO {$db_prefix}themes (id_theme, variable, value) VALUES (1, 'show_member_bar', '1');
  2134. INSERT INTO {$db_prefix}themes (id_theme, variable, value) VALUES (1, 'linktree_link', '1');
  2135. INSERT INTO {$db_prefix}themes (id_theme, variable, value) VALUES (1, 'show_profile_buttons', '1');
  2136. INSERT INTO {$db_prefix}themes (id_theme, variable, value) VALUES (1, 'show_mark_read', '1');
  2137. INSERT INTO {$db_prefix}themes (id_theme, variable, value) VALUES (1, 'show_stats_index', '1');
  2138. INSERT INTO {$db_prefix}themes (id_theme, variable, value) VALUES (1, 'show_board_desc', '1');
  2139. INSERT INTO {$db_prefix}themes (id_theme, variable, value) VALUES (1, 'newsfader_time', '5000');
  2140. INSERT INTO {$db_prefix}themes (id_theme, variable, value) VALUES (1, 'allow_no_censored', '0');
  2141. INSERT INTO {$db_prefix}themes (id_theme, variable, value) VALUES (1, 'additional_options_collapsable', '1');
  2142. INSERT INTO {$db_prefix}themes (id_theme, variable, value) VALUES (1, 'use_image_buttons', '1');
  2143. INSERT INTO {$db_prefix}themes (id_theme, variable, value) VALUES (1, 'enable_news', '1');
  2144. INSERT INTO {$db_prefix}themes (id_theme, variable, value) VALUES (1, 'forum_width', '90%');
  2145. INSERT INTO {$db_prefix}themes (id_theme, variable, value) VALUES (2, 'name', '{$default_core_theme_name}');
  2146. INSERT INTO {$db_prefix}themes (id_theme, variable, value) VALUES (2, 'theme_url', '{$boardurl}/Themes/core');
  2147. INSERT INTO {$db_prefix}themes (id_theme, variable, value) VALUES (2, 'images_url', '{$boardurl}/Themes/core/images');
  2148. INSERT INTO {$db_prefix}themes (id_theme, variable, value) VALUES (2, 'theme_dir', '{$boarddir}/Themes/core');
  2149. INSERT INTO {$db_prefix}themes (id_member, id_theme, variable, value) VALUES (-1, 1, 'display_quick_reply', '1');
  2150. INSERT INTO {$db_prefix}themes (id_member, id_theme, variable, value) VALUES (-1, 1, 'posts_apply_ignore_list', '1');
  2151. # --------------------------------------------------------
  2152. #
  2153. # Sequence for table `topics`
  2154. #
  2155. CREATE SEQUENCE {$db_prefix}topics_seq START WITH 2;
  2156. #
  2157. # Table structure for table `topics`
  2158. #
  2159. CREATE TABLE {$db_prefix}topics (
  2160. id_topic int default nextval('{$db_prefix}topics_seq'),
  2161. is_sticky smallint NOT NULL default '0',
  2162. id_board smallint NOT NULL default '0',
  2163. id_first_msg int NOT NULL default '0',
  2164. id_last_msg int NOT NULL default '0',
  2165. id_member_started int NOT NULL default '0',
  2166. id_member_updated int NOT NULL default '0',
  2167. id_poll int NOT NULL default '0',
  2168. id_previous_board smallint NOT NULL default '0',
  2169. id_previous_topic int NOT NULL default '0',
  2170. num_replies int NOT NULL default '0',
  2171. num_views int NOT NULL default '0',
  2172. locked smallint NOT NULL default '0',
  2173. unapproved_posts smallint NOT NULL default '0',
  2174. approved smallint NOT NULL default '1',
  2175. PRIMARY KEY (id_topic)
  2176. );
  2177. #
  2178. # Indexes for table `topics`
  2179. #
  2180. CREATE UNIQUE INDEX {$db_prefix}topics_last_message ON {$db_prefix}topics (id_last_msg, id_board);
  2181. CREATE UNIQUE INDEX {$db_prefix}topics_first_message ON {$db_prefix}topics (id_first_msg, id_board);
  2182. CREATE UNIQUE INDEX {$db_prefix}topics_poll ON {$db_prefix}topics (id_poll, id_topic);
  2183. CREATE INDEX {$db_prefix}topics_is_sticky ON {$db_prefix}topics (is_sticky);
  2184. CREATE INDEX {$db_prefix}topics_approved ON {$db_prefix}topics (approved);
  2185. CREATE INDEX {$db_prefix}topics_id_board ON {$db_prefix}topics (id_board);
  2186. CREATE INDEX {$db_prefix}topics_member_started ON {$db_prefix}topics (id_member_started, id_board);
  2187. CREATE INDEX {$db_prefix}topics_last_message_sticky ON {$db_prefix}topics (id_board, is_sticky, id_last_msg);
  2188. CREATE INDEX {$db_prefix}topics_board_news ON {$db_prefix}topics (id_board, id_first_msg);
  2189. #
  2190. # Dumping data for table `topics`
  2191. #
  2192. INSERT INTO {$db_prefix}topics
  2193. (id_topic, id_board, id_first_msg, id_last_msg, id_member_started, id_member_updated)
  2194. VALUES (1, 1, 1, 1, 0, 0);
  2195. # --------------------------------------------------------