[DBAL-297] PDO::PARAM_LOB (value=3) overlaps with PDO::FETCH_NUM (value=3) in OCI8Statement::$fetchModeMap Created: 05/Jul/12  Updated: 21/Nov/13  Resolved: 21/Nov/13

Status: Resolved
Project: Doctrine DBAL
Component/s: Drivers
Affects Version/s: None
Fix Version/s: 2.5
Security Level: All

Type: Bug Priority: Minor
Reporter: Charles Gunawan Assignee: Benjamin Eberlei
Resolution: Fixed Votes: 0
Labels: None
Environment:

N/A



 Description   

Hi,

In OCI8Statement, using PDO::FETCH_NUM does not work because the fetch style mapping is overwritten by PDO::PARAM_LOB since the two has the same value (3);

protected static $fetchModeMap = array(
PDO::FETCH_BOTH => OCI_BOTH,
PDO::FETCH_ASSOC => OCI_ASSOC,
PDO::FETCH_NUM => OCI_NUM,
PDO::PARAM_LOB => OCI_B_BLOB,
PDO::FETCH_COLUMN => OCI_NUM,
);

so PDO::FETCH_NUM is mapped to OCI_B_BLOB



 Comments   
Comment by Steve Müller [ 21/Nov/13 ]

Fixed in https://github.com/doctrine/dbal/commit/642245644392f3b9c34c75af57d322a81317becb#diff-2a71cb2283aa305e363a1dd8254976dd

Generated at Sat Apr 19 10:37:42 UTC 2014 using JIRA 6.2.3#6260-sha1:63ef1d6dac3f4f4d7db4c1effd405ba38ccdc558.