[wp-testers] Someone found some possible db error spitting code...

spencerp spencerp1 at gmail.com
Tue Sep 25 11:32:11 GMT 2007


"i had this error in the frontpage after upgrade to 2.3

    WordPress database error: [Table 'a19108.wp_categories' doesn't exist]
    SELECT cat_id, cat_name FROM wp_categories WHERE link_count >= 1 "


"i deactivate all plug-ins, one by one, and the message didn't disappear

the problematic code is:

    <?php if ( !function_exists('dynamic_sidebar') || 
!dynamic_sidebar('sidebar_right') ) : ?>
    <h2>Archives</h2>

          <?php wp_get_archives('type=yearly'); ?>

    <?php
    if (wp_version() == '20') {
    $link_cats = $wpdb->get_results("SELECT cat_id, cat_name FROM 
$wpdb->linkcategories");
    }
    else {
    $link_cats = $wpdb->get_results("SELECT cat_id, cat_name FROM 
$wpdb->categories WHERE link_count >= 1");
    }
    foreach ($link_cats as $link_cat) {
    ?>

    <?php } ?>
    <?php endif; ?>"

http://wordpress.org/support/topic/135561?replies=5

Is there a way a Moderator or Admin could post a sticky post regarding 
Themes and 2.3 changes? This is ONE thing that's causing alot of 
Database Errors and them posting about them in the forums...

--
spencerp
http://spencerp.net
http://www.vindictivebastard.net




More information about the wp-testers mailing list