Changeset 640
- Timestamp:
- 01/22/2007 06:47:52 PM (19 years ago)
- Location:
- trunk/bb-admin
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/bb-admin/upgrade-schema.php
r516 r640 38 38 forum_id int(10) NOT NULL default '1', 39 39 topic_status tinyint(1) NOT NULL default '0', 40 topic_resolved varchar(15) NOT NULL default 'no',41 40 topic_open tinyint(1) NOT NULL default '1', 42 41 topic_last_post_id bigint(20) NOT NULL default '1', -
trunk/bb-admin/upgrade.php
r631 r640 125 125 upgrade_170(); // Escaping in usermeta 126 126 upgrade_180(); // Delete users for real 127 upgrade_190(); // Move topic_resolved to topicmeta 127 128 128 129 //alter user table column names … … 261 262 function upgrade_180() { 262 263 if ( ( $dbv = bb_get_option( 'bb_db_version' ) ) && $dbv >= 559 ) 263 264 return; 264 265 265 266 global $bbdb; … … 271 272 } 272 273 274 function upgrade_190() { 275 if ( ( $dbv = bb_get_option( 'bb_db_version' ) ) && $dbv >= 630 ) 276 return; 277 278 global $bbdb; 279 $topics = (array) $bbdb->get_results("SELECT topic_id, topic_resolved FROM $bbdb->topics" ); 280 foreach ( $topics as $topic ) 281 bb_update_topicmeta( $topic->topic_id, 'topic_resolved', $topic->topic_resolved ); 282 unset($topics,$topic); 283 284 $bbdb->query("ALTER TABLE $bbdb->topics DROP topic_resolved"); 285 286 bb_update_option( 'bb_db_version', 630 ); 287 288 echo "Done converting topic_resolved.<br />"; 289 } 290 273 291 function deslash($content) { 274 292 // Note: \\\ inside a regex denotes a single backslash.
Note: See TracChangeset
for help on using the changeset viewer.