From:             ssufficool at roadrunner dot com
Operating system: Linux Gentoo 2.6.x
PHP version:      5.2.9
PHP Bug Type:     PDO related
Bug description:  DBLIB barfs on quoted field names

Description:
------------
When passing a query containing double quoted field names, the query
fails. 

Reproduce code:
---------------
$pdo_ms = new PDO('dblib:host=db01;dbname=database',
$_SESSION['user'], $_SESSION['pass'], array(PDO::ATTR_ERRMODE =>
PDO::ERRMODE_EXCEPTION ) );

$rs = $pdo_ms->prepare('SELECT "myView"."FieldName" from "myView" order by
"Some Field"')


Expected result:
----------------
A valid handle to a stmt in $rs


Actual result:
--------------
SQLSTATE[HY000]: General error: 20018 Incorrect syntax near 'FieldName'.
[20018] (severity 5) [(null)]


-- 
Edit bug report at http://bugs.php.net/?id=47588&edit=1
-- 
Try a CVS snapshot (PHP 5.2):        
http://bugs.php.net/fix.php?id=47588&r=trysnapshot52
Try a CVS snapshot (PHP 5.3):        
http://bugs.php.net/fix.php?id=47588&r=trysnapshot53
Try a CVS snapshot (PHP 6.0):        
http://bugs.php.net/fix.php?id=47588&r=trysnapshot60
Fixed in CVS:                        
http://bugs.php.net/fix.php?id=47588&r=fixedcvs
Fixed in CVS and need be documented: 
http://bugs.php.net/fix.php?id=47588&r=needdocs
Fixed in release:                    
http://bugs.php.net/fix.php?id=47588&r=alreadyfixed
Need backtrace:                      
http://bugs.php.net/fix.php?id=47588&r=needtrace
Need Reproduce Script:               
http://bugs.php.net/fix.php?id=47588&r=needscript
Try newer version:                   
http://bugs.php.net/fix.php?id=47588&r=oldversion
Not developer issue:                 
http://bugs.php.net/fix.php?id=47588&r=support
Expected behavior:                   
http://bugs.php.net/fix.php?id=47588&r=notwrong
Not enough info:                     
http://bugs.php.net/fix.php?id=47588&r=notenoughinfo
Submitted twice:                     
http://bugs.php.net/fix.php?id=47588&r=submittedtwice
register_globals:                    
http://bugs.php.net/fix.php?id=47588&r=globals
PHP 4 support discontinued:          http://bugs.php.net/fix.php?id=47588&r=php4
Daylight Savings:                    http://bugs.php.net/fix.php?id=47588&r=dst
IIS Stability:                       
http://bugs.php.net/fix.php?id=47588&r=isapi
Install GNU Sed:                     
http://bugs.php.net/fix.php?id=47588&r=gnused
Floating point limitations:          
http://bugs.php.net/fix.php?id=47588&r=float
No Zend Extensions:                  
http://bugs.php.net/fix.php?id=47588&r=nozend
MySQL Configuration Error:           
http://bugs.php.net/fix.php?id=47588&r=mysqlcfg

Reply via email to