• HELP!!! I’m tearing my hair out.

    WordPress 4.4.1
    Wordpress-Database-Abstraction 1.1.4

    Windows 2012 Datacenter
    SQL Server 2012 Standard

    Had to manually create (using the sample file) wp-config.php

    /** MySQL database username */
    define('DB_USER', 'userid');
    
    /** MySQL database password */
    define('DB_PASSWORD', 'password');
    
    /** MySQL hostname */
    define('DB_HOST', 'localhost');
    
    /** Database Charset to use in creating database tables. */
    define('DB_CHARSET', 'utf8');
    
    /** The Database Collate type. Don't change this if in doubt. */
    define('DB_COLLATE', '');
    
    /** The Database Type. */
    define('DB_TYPE', 'pdo_sqlsrv');

    When I try to run the install.php, I continually get the “Error establishing a database connection”.

    SQL Server Mixed Mode authentication: yes
    PHP Manager shows the pdo_sqlsrv.dll among all the other prerequisite dlls are enabled.

    I’ve run a test db connection web page and it show a valid connection. So I don’t know what to do. Help!!!

    sample test.php code snippet to test db connection (this works!)

    $serverName = "localhost";
    $conn1 = new PDO( "sqlsrv:server=$serverName ; Database=mydbname", "userid", "password");
    $conn1->setAttribute( PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION );
    
    if( $conn1 ) {
         echo "Connection1 established.<br />";
    }else{
         echo "Connection1 could not be established.<br />";
         die( print_r( sqlsrv_errors(), true));
    }
Viewing 1 replies (of 1 total)
  • Moderator Jan Dembowski

    (@jdembowski)

    Forum Moderator and Brute Squad

    The short answer? You can’t use Microsoft SQL server, any version.

    Longer version: there was a plugin from the pre-history of mankind that may have worked at one time but stopped working for years. Too much has changed in WordPress for that plugin to support that layer of abstraction.

    You can try to make it work but honestly, it won’t. Use one of the many MySQL implementation instead.

    Edit: This plugin.

    https://www.ads-software.com/plugins/wordpress-database-abstraction/

    Which hasn’t been touched in 4 years.

Viewing 1 replies (of 1 total)
  • The topic ‘WordPress on Windows 2012 using SQL Server 2012 Standard’ is closed to new replies.