Title: wp_users doesn&#8217;t exist
Last modified: August 18, 2016

---

# wp_users doesn’t exist

 *  [brandondrury](https://wordpress.org/support/users/brandondrury/)
 * (@brandondrury)
 * [18 years, 12 months ago](https://wordpress.org/support/topic/wp_users-doesnt-exist/)
 * Last night I switched servers on my site and now I have a problem.
 * I created a left hand column for wordpress where I do a php include of ‘left.
   php’. In left.php, there is code that selects my sites categories via MySQL (
   these categories exist outside of wordpress and are totally different part of
   my site).
 * The problem is mysql_connect and mysql_select_db. I must be dropping the connection
   to the WordPress database and then connecting to my custom database. This would
   explain why I get the following error.
 *     ```
       WordPress database error: [Table 'textl3_MyCustomdB.wp_users' doesn't exist]
       SELECT * FROM wp_users WHERE ID = '2' LIMIT 1
       ```
   
 * It’s clear that WordPress is looking for wp_users in MyCustomdB and not in the
   WordPressdB.
 * So, is there a way that I can reconnect to the WordPressdB immediately after 
   executing my left.php code?

The topic ‘wp_users doesn’t exist’ is closed to new replies.

## Tags

 * [MySQL](https://wordpress.org/support/topic-tag/mysql/)
 * [wp_users](https://wordpress.org/support/topic-tag/wp_users/)

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 0 replies
 * 1 participant
 * Last reply from: [brandondrury](https://wordpress.org/support/users/brandondrury/)
 * Last activity: [18 years, 12 months ago](https://wordpress.org/support/topic/wp_users-doesnt-exist/)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
