WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] SQL Error Creating Network (4 posts)

  1. cwalls
    Member
    Posted 6 months ago #

    This is a WordPress installation on Windows 2008 R2, IIS 7.5, and SQL Server 2008 R2. The initial installation works fine. We have plug-in operating, custom themes installed, and are able to create posts, users, etc.

    I have been following the instructions as https://codex.wordpress.org/Create_A_Network to create a multi-site installation.

    When I get to step three and click Install to create the network, I get a generic Server Error 500. When I check the PHP logs, I find the following:

    [27-Feb-2014 21:22:01 UTC] WordPress database error [Microsoft][SQL Server Native Client 11.0][SQL Server]Incorrect syntax near 'wp_site'. for query SELECT TABLE_NAME FROM INFORMATION_SCHEMA.TABLES WHERE TABLE_NAME LIKE ''wp_site'' made by network_domain_check, sqlsrv_wpdb->query, sqlsrv_wpdb->_post_query, sqlsrv_wpdb->print_error
    [27-Feb-2014 21:22:01 UTC] WordPress database error [Microsoft][SQL Server Native Client 11.0][SQL Server]Incorrect syntax near 'wp_site'. for query SELECT TABLE_NAME FROM INFORMATION_SCHEMA.TABLES WHERE TABLE_NAME LIKE ''wp_site'' made by network_domain_check, sqlsrv_wpdb->query, sqlsrv_wpdb->_post_query, sqlsrv_wpdb->print_error
    [27-Feb-2014 21:22:01 UTC] WordPress database error [Microsoft][SQL Server Native Client 11.0][SQL Server]Incorrect syntax near 'wp_site'. for query SELECT TABLE_NAME FROM INFORMATION_SCHEMA.TABLES WHERE TABLE_NAME LIKE ''wp_site'' made by network_step1, get_clean_basedomain, network_domain_check, sqlsrv_wpdb->query, sqlsrv_wpdb->_post_query, sqlsrv_wpdb->print_error
    [27-Feb-2014 21:22:03 UTC] WordPress database error [Microsoft][SQL Server Native Client 11.0][SQL Server]Incorrect syntax near 'wp_site'. for query SELECT TABLE_NAME FROM INFORMATION_SCHEMA.TABLES WHERE TABLE_NAME LIKE ''wp_site'' made by network_domain_check, sqlsrv_wpdb->query, sqlsrv_wpdb->_post_query, sqlsrv_wpdb->print_error
    [27-Feb-2014 21:22:04 UTC] WordPress database error [Microsoft][SQL Server Native Client 11.0][SQL Server]Incorrect syntax near 'wp_site'. for query SELECT TABLE_NAME FROM INFORMATION_SCHEMA.TABLES WHERE TABLE_NAME LIKE ''wp_site'' made by network_domain_check, sqlsrv_wpdb->query, sqlsrv_wpdb->_post_query, sqlsrv_wpdb->print_error
    [27-Feb-2014 21:22:04 UTC] WordPress database error [Microsoft][SQL Server Native Client 11.0][SQL Server]Incorrect syntax near 'wp_site'. for query SELECT TABLE_NAME FROM INFORMATION_SCHEMA.TABLES WHERE TABLE_NAME LIKE ''wp_site'' made by get_clean_basedomain, network_domain_check, sqlsrv_wpdb->query, sqlsrv_wpdb->_post_query, sqlsrv_wpdb->print_error
    [27-Feb-2014 21:22:04 UTC] WordPress database error [Microsoft][SQL Server Native Client 11.0][SQL Server]Incorrect syntax near 'wp_site'. for query SELECT TABLE_NAME FROM INFORMATION_SCHEMA.TABLES WHERE TABLE_NAME LIKE ''wp_site'' made by network_step1, get_clean_basedomain, network_domain_check, sqlsrv_wpdb->query, sqlsrv_wpdb->_post_query, sqlsrv_wpdb->print_error
    [27-Feb-2014 21:15:47 UTC] WordPress database error [Microsoft][SQL Server Native Client 11.0][SQL Server]Cannot insert explicit value for identity column in table 'wp_blogs' when IDENTITY_INSERT is set to OFF. for query INSERT INTO wp_blogs (site_id,blog_id,domain,path,registered) VALUES (1,1, N'Example.com', N'/', N'2014-02-27 15:15:47') made by populate_network, sqlsrv_wpdb->query, sqlsrv_wpdb->_post_query, sqlsrv_wpdb->print_error
    1. It's obvious what is incorrect with the LIKE ''wp_site'' portion of the first 6 log statements. Any ideas on how to remove the duplicate single quotes?
    2. For the IDENTITY_INSERT issue, this must be localized to the install network functionality because I'm able to create posts, and that table's primary key is also defined as an identity field. Any ideas on how to fix this?

    Any help would be appreciated.

  2. What's your DB prefix?

  3. cwalls
    Member
    Posted 6 months ago #

    From the wp-config.php file: $table_prefix = 'wp_';

  4. cwalls
    Member
    Posted 6 months ago #

    I'm not sure how, but I got past this issue. I restored my database and WordPress and walked through the setup again and managed to get past this. I tried this a few times yesterday to no avail.

Reply

You must log in to post.

About this Topic