php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #62551 oci_bind_by_name() : maxlength and memory usage
Submitted: 2012-07-13 12:54 UTC Modified: 2013-02-18 00:35 UTC
From: tbrillaud at meti dot fr Assigned: sixd (profile)
Status: No Feedback Package: OCI8 related
PHP Version: 5.3.14 OS: Linux
Private report: No CVE-ID: None
View Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
If you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: tbrillaud at meti dot fr
New email:
PHP Version: OS:

 

 [2012-07-13 12:54 UTC] tbrillaud at meti dot fr
Description:
------------
The variable maxlength has no effect in the memory usage for a bind variable OUT.

A bind variable OUT takes systematically 65536 bytes in memory.

Test script:
---------------
$sql = "CALL TEST.PROC_OUT(:OUT)";
$curseur = oci_parse($connexion, $sql);
$out="1";
$size=10;
oci_bind_by_name($curseur,":OUT", $out, $size);

var_dump(memory_get_usage());
$ok = oci_execute($curseur);
oci_free_statement($curseur);
var_dump(memory_get_usage());


Expected result:
----------------
Memory should be consistency with the maxlength parameter.

Actual result:
--------------
Playing with memory settings, we obtain :

PHP Fatal error:  Allowed memory size of 10752000 bytes exhausted (tried to allocate 65536 bytes) 

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2012-10-03 02:37 UTC] sixd@php.net
-Status: Open +Status: Feedback
 [2012-10-03 02:37 UTC] sixd@php.net
Please give a complete testcase, including the DDL to create the procedure 
showing the datatype being using.
 [2012-11-05 00:15 UTC] sixd@php.net
-Assigned To: +Assigned To: sixd
 [2013-02-18 00:35 UTC] php-bugs at lists dot php dot net
No feedback was provided. The bug is being suspended because
we assume that you are no longer experiencing the problem.
If this is not the case and you are able to provide the
information that was requested earlier, please do so and
change the status of the bug back to "Open". Thank you.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sat Dec 14 11:01:27 2024 UTC