Jira issue originally created by user johnarevalo:
trying to execute this dql:
SELECT p FROM my\namespace\entities\PQR p WHERE p.razon = 'TEL'
it built this native sql (iseries)
SELECT t0.SGNUMÑ AS SGNUMÑ0, t0_.SGCAUS AS SGCAUS1, t0_.SGREAS AS SGREAS2 FROM SGMASTL7 t0_ WHERE t0.SGCAUS =
because pdo is created with odbc, quote method is not supported, and Doctrine/DBAL/Connection.php#quote() method returns an empty value for <'TEL'> expression, so Database throws a Syntax error. It should be support for drivers which doesn't have implemented quote() method.
 with odbc: $pdo = new PDO("odbc:MYODBCNAME", "USER", "PASSWORD");
Comment created by @beberlei:
As a first trick you can use the wrapperClass parameter to the DriverManager factory and create your "MyConnection extends \Doctrine\DBAL\Connection" to solve this issue.
Closed, odbc is not a supported driver.
Issue was closed with resolution "Can't Fix"