Skip to content



doctrinebot opened this Issue · 5 comments

2 participants


Jira issue originally created by user stcoid1:

Hi, master...

Please help me,
i was integration : ci2doctrine2pdo_mysql status is OK
php.ini ===> phpinfo()

But ci2doctrine2pdo_sqlsrv. Show bugs this :

"Fatal error: Uncaught exception 'PDOException' with message 'SQLSTATE[IMSSP]: This extension requires either the Microsoft SQL Server 2008 Native Client (SP1 or later) or the Microsoft SQL Server 2008 R2 Native Client ODBC Driver to communicate with SQL Server. Neither of those ODBC Drivers are currently installed. Access the following URL to download the Microsoft SQL Server 2008 R2 Native Client ODBC driver for x86:' in C:\xampp\htdocs\sqlserver\application\thirdparty\doctrine-orm\Doctrine\DBAL\Driver\PDOConnection.php:36 Stack trace: #0 C:\xampp\htdocs\sqlserver\application\third_party\doctrine-orm\Doctrine\DBAL\Driver\PDOConnection.php(36): PDO->__construct('sqlsrv:server=B...', 'sa', 'password', Array) #1 C:\xampp\htdocs\sqlserver\application\third_party\doctrine-orm\Doctrine\DBAL\Driver\PDOSqlsrv\Driver.php(38): Doctrine\DBAL\Driver\PDOConnection->__construct('sqlsrv:server=B...', 'sa', 'password', Array) #2 C:\xampp\htdocs\sqlserver\application\third_party\doct in C:\xampp\htdocs\sqlserver\application\thirdparty\doctrine-orm\Doctrine\DBAL\Driver\PDOConnection.php on line 36"



Comment created by stcoid1:

This Problem is resolve with SQL Server 2008.

But i have new problem, paging is Error

"Fatal error: Uncaught exception 'PDOException' with message 'SQLSTATE[42000]: [Microsoft][SQL Server Native Client 10.0][SQL Server]The multi-part identifier "c0.group_company_code" could not be bound.' in C:\xampp\htdocs\sqlserver\application\third_party\doctrine-orm\Doctrine\DBAL\Connection.php:577 Stack trace: #0 C:\xampp\htdocs\sqlserver\application\third_party\doctrine-orm\Doctrine\DBAL\Connection.php(577): PDO->query('WITH outer_tbl ...') #1 C:\xampp\htdocs\sqlserver\application\third_party\doctrine-orm\Doctrine\ORM\Query\Exec\SingleSelectExecutor.php(46): Doctrine\DBAL\Connection->executeQuery('WITH outer_tbl ...', Array, Array) #2 C:\xampp\htdocs\sqlserver\application\third_party\doctrine-orm\Doctrine\ORM\Query.php(274): Doctrine\ORM\Query\Exec\SingleSelectExecutor->execute(Object(Doctrine\DBAL\Connection), Array, Array) #3 C:\xampp\htdocs\sqlserver\application\third_party\doctrine-orm\Doctrine\ORM\AbstractQuery.php(539): Doctrine\ORM\Query->_doExecute() #4 C:\xampp\htdocs\sqlserver\application\third_party\doctri in C:\xampp\htdocs\sqlserver\application\thirdparty\doctrine-orm\Doctrine\DBAL\Connection.php on line 577"

This link*group/posts/list_company*group

Any body help...



Comment created by stcoid1:

Problem Resolve

go into:

$over = preg*replace('/\"[<sup>,]*\".\"([</sup>,]*)\"/i', '"inner*tbl"."$1"', $orderby);

Add before:

                    # Get Columns
                    $columns = array();
                    if(preg*match_all('/([a-zA-Z][0-9]<ins>_\.[a-zA-Z0-9\-_]</ins>)\sAS\s([a-zA-Z0-9\-\*]<ins>)/', $query, $matched)) {
                        for($i=0; $i<count($matched[1]); </ins><ins>$i)
                            $columns[$matched[1][$i]] = $matched[2][$i];

                    # Replace columns with their alias in the "orderby" statement
                    if(preg*match_all('/([a-zA-Z][0-9]</ins>_\.[a-zA-Z0-9\-*]+)\s/i', $orderby, $matches)) {
                        foreach($matches[1] as $column)
                            $orderby = preg_replace('/'.$column.'/', $columns[$column], $orderby);

Thanks on issue this link "[DBAL-82]("


Comment created by @beberlei:

CAn you post the query that leads to this error? I cant reproduce it with SQL Server 2008


Comment created by @beberlei:

This was fixed in other issues already


Issue was closed with resolution "Duplicate"

@doctrinebot doctrinebot added the Bug label
@beberlei beberlei was assigned by doctrinebot
@doctrinebot doctrinebot closed this
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.