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

---

# wp_posts’ table doesn’t exist

 *  [heyrsmith](https://wordpress.org/support/users/heyrsmith/)
 * (@heyrsmith)
 * [19 years, 3 months ago](https://wordpress.org/support/topic/wp_posts-table-doesnt-exist/)
 * database error: [Table ‘soa.wp_posts’ doesn’t exist]
    SELECT DISTINCT * FROM 
   wp_posts WHERE 1=1 AND post_date_gmt Out of the blue I have a wordpress install
   that is generating the following errors:
 *     ```
       <= '2007-03-08 02:18:59' AND (post_status = "publish" OR post_author = 2 AND post_status != 'draft' AND post_status != 'static') AND post_status != "attachment" GROUP BY wp_posts.ID ORDER BY post_date DESC LIMIT 0, 3
   
       database error: [Table 'soa.wp_posts' doesn't exist]
       SELECT DISTINCT YEAR(post_date) AS <code>year</code>, MONTH(post_date) AS <code>month</code>, count(ID) as posts FROM wp_posts WHERE post_date < '2007-03-07 20:18:39' AND post_date != '0000-00-00 00:00:00' AND post_status = 'publish' GROUP BY YEAR(post_date), MONTH(post_date) ORDER BY post_date DESC
       ```
   
 * You may see it here: [http://www.cadc.auburn.edu/soa/](http://www.cadc.auburn.edu/soa/)
 * I currently have all plugins turned off, so you will see a few other errors as
   well – ignore those if you can. This install is on a windows IIS machine – I 
   do not have a way to look at the database to see if the table actually has gone
   missing, but I assume that it has by the error. I have not done anything to the
   site in a couple of weeks, so I am guessing maybe a corrupt database file maybe?
   Anybody think that reverting the database file to a previously saved version 
   my do the trick in fixing it, or is it something much more obvious than that?

Viewing 2 replies - 1 through 2 (of 2 total)

 *  [drmike](https://wordpress.org/support/users/drmike/)
 * (@drmike)
 * [19 years, 3 months ago](https://wordpress.org/support/topic/wp_posts-table-doesnt-exist/#post-534683)
 * Silly question: Does the table exist? Are you able to pull it up in something
   like phpmyadmin and check it out? Any errors when you do?
 * You come up with some solutions but it appears you haven’t reviewed any of them
   yet.
 *  Thread Starter [heyrsmith](https://wordpress.org/support/users/heyrsmith/)
 * (@heyrsmith)
 * [19 years, 3 months ago](https://wordpress.org/support/topic/wp_posts-table-doesnt-exist/#post-534701)
 * Hey drmike, thanks for responding – no, not a silly question at all. Yes, my 
   solutions were ahead of the gun a bit – This particular install is one that is
   tightly controlled by our admin folks and I do not have direct access to the 
   DB – there is a (slight) institutional reluctance to service this install, so
   I always feel like it is important to be able to understand what might be going
   on and suggest ways of fixing it.
 * What our support person was able to tell me this morning is that
 * > …one of the tables apparently had more data in it than was set in the database
   > structure… for example, the structure was set to allow no more than 100 characters
   > and ….it had well more than that…I have upped that to 255 characters and the
   > site “looks” OK….
   > …also the DB was completely screwed up though and several tables are barking
   > at me that they need repaired and re-indexing…
 * So that seems to have fixed it for now. We also had a particular page throwing
   the following error:
 * > database error: [Data too long for column ‘useragent’ at row 1]
   >  INSERT INTO
   > wp_useronline VALUES (‘1173176402’, ‘Guest’, ‘Mozilla/4.0 (compatible; MSIE
   > 7.0; Windows NT 5.1; InfoPath.1; .NET CLR 2.0.50727; .NET CLR 3.0.04506.30;.
   > NET CLR 1.1.4322)’, ‘131.204.119.146’, ‘auSofA » Graduate Program in Community
   > Planning’, ‘%2Fsoa%2Findex.php%2Fprograms%2Fmcp%2F’)
 * Which seems to be the place where there is “too much data” The upping of the 
   character limit has fixed that error too. My support person followed up with:
 * > Yep that’s the problem right there….so there was too much in the database in
   > that field..and it “probably” caused the indexing to screw all up.
 * That particular error looks like it may be caused by the wp_useronline plugin,
   which has never caused any problems before… Our support is unable to offer any
   observations as to how this happened or possible ways to keep it from re-occurring
   in the future.
 * So I guess I am left with the following questions:
    1. How does this happen and is it normal?
    2. Does the fix make sense?
    3. Is there a way to avoid this in the future?
 * Thanks in advance for any observations…

Viewing 2 replies - 1 through 2 (of 2 total)

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

## Tags

 * [table](https://wordpress.org/support/topic-tag/table/)
 * [wp_posts](https://wordpress.org/support/topic-tag/wp_posts/)

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 2 replies
 * 2 participants
 * Last reply from: [heyrsmith](https://wordpress.org/support/users/heyrsmith/)
 * Last activity: [19 years, 3 months ago](https://wordpress.org/support/topic/wp_posts-table-doesnt-exist/#post-534701)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
