Title: Multisite DB error table &#8216;options&#8217; doesn&#8217;t exist
Last modified: July 27, 2020

---

# Multisite DB error table ‘options’ doesn’t exist

 *  [bu130932](https://wordpress.org/support/users/stham/)
 * (@stham)
 * [5 years, 10 months ago](https://wordpress.org/support/topic/multisite-db-error-table-options-doesnt-exist/)
 * I’m writing a plugin that needs to create a custom db table upon activation. 
   The plugin is for a multisite and because the table is needed for every single
   site, the plugin is network activated.
 * After a new site is created, the custom db table is created and then I store 
   a value in the options table to indicate which version the db table design is.
 * However, I am seeing the following in the error_log:
    `WordPress database error
   Table 'network.site_14_options' doesn't exist for query INSERT INTO`site_14_options`(`
   option_name`,`option_value`,`autoload`) VALUES ('prefix_plugin_db_version', '
   2', 'yes') ON DUPLICATE KEY UPDATE`option_name`= VALUES(`option_name`),`option_value`
   = VALUES(`option_value`),`autoload`= VALUES(`autoload`) made by wpmu_create_blog,
   wp_insert_site, do_action('wp_insert_site'), WP_Hook->do_action, WP_Hook->apply_filters,
   Plugin_Activator::new_blog_created, Plugin_Activator::install, Plugin_Activator::
   create_table, update_option, add_option`
 * I am using the `wp_insert_site` hook to create the custom db tables when a new
   site is created. Is this not the right hook for me to be using? Which one should
   I use instead?
 * Thanks!
    -  This topic was modified 5 years, 10 months ago by [Jan Dembowski](https://wordpress.org/support/users/jdembowski/).
      Reason: Moved to Fixing WordPress, this is not an Developing with WordPress
      topic

The topic ‘Multisite DB error table ‘options’ doesn’t exist’ is closed to new replies.

## Tags

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

 * In: [Networking WordPress](https://wordpress.org/support/forum/multisite/)
 * 0 replies
 * 1 participant
 * Last reply from: [bu130932](https://wordpress.org/support/users/stham/)
 * Last activity: [5 years, 10 months ago](https://wordpress.org/support/topic/multisite-db-error-table-options-doesnt-exist/)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
