php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #56861 xmltype insert crashes
Submitted: 2006-02-26 12:02 UTC Modified: 2021-05-16 04:22 UTC
Votes:1
Avg. Score:3.0 ± 0.0
Reproduced:0 of 0 (0.0%)
From: trevor dot lowing at gmail dot com Assigned: cmb (profile)
Status: No Feedback Package: PDO OCI
PHP Version: 5.1.1 OS: Windows XP
Private report: No CVE-ID: None
Have you experienced this issue?
Rate the importance of this bug to you:

 [2006-02-26 12:02 UTC] trevor dot lowing at gmail dot com
Description:
------------
I am using the PDO extension to do record operations on a 9i DB on Windows XP (Apache/2.0.50 (Win32) DAV/2 PHP/5.1.1). Not having any issues with date and string type columns but attempting to insert into a xmltype/clob column throws an Apache exception. I've tried the blob exampleI am using the PDO extension to do record operations on a 9i DB on Windows XP (Apache/2.0.50 (Win32) DAV/2 PHP/5.1.1). Not having any issues with date and string type columns but attempting to insert into a xmltype/clob column throws an Apache exception. I've tried the blob example from the PHP docs and another article ( http://netevil.org/node.php?uuid=4365876a-cee9-3009-7726-365876a51802) with the same results:

Apache.exe - Application Error

The instruction at "0x612e4e8f" referenced memory at "0x000000420". The memory could not be "read"

I try to catch the PDOException but the error is thrown by Apache. 

Reproduce code:
---------------
$db = new PDO('oci:', 'dew', 'password');
    $db->beginTransaction();
    $stmt = $db->prepare("insert into RECORD (RECORD_XML_TX)
    VALUES (EMPTY_CLOB()) RETURNING RECORD_XML_TX INTO ?)");
     // Open file for writing
     $fp = @fopen("tmp.xml","a+") or die("Could not open file");

    $stmt->bindParam(1,$fp, PDO::PARAM_LOB);
    try {
        $stmt->execute();
    } catch (PDOException $e) {
        echo  $e->getMessage() . "<br/>";
        die();
    }
    $stmt->commit();
     // Close the file
     @fclose($fp);


Expected result:
----------------
Have xml inserted into the RECORD.RECORD_XML_TX xmltype column. I've done inserts using the OCI extension on the same database without any problems. As I mentioned, other column types work perfectly.

Actual result:
--------------
Apache.exe - Application Error

The instruction at "0x612e4e8f" referenced memory at "0x000000420". The memory could not be "read"


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2008-03-05 07:38 UTC] ai dot revolutions at gmail dot com
Hi Trevor,

I managed to correct the bug here. I happened to have SoftICE debugger running in the background. So, ensure you don't have a system debugger running at your place too. 

Also try to disable some database services at startup, notable the 9i one, and if you have IIS or any other webserving services, disable them. Restart your machine and start Apache first. Then start the other services you stopped. If that worked, google a good way to start Apache before any other service. Good luck. Hope that helps!

Come back if it doesn't, we shall try another thing together.

Email : ai [dot] revolutions [at] gmail [dot] com

Shailen Sobhee
Mauritius
http://digitalgraphy.wordpress.com
 [2021-05-03 11:36 UTC] cmb@php.net
-Status: Open +Status: Feedback -Package: PDO_OCI +Package: PDO OCI -Assigned To: +Assigned To: cmb
 [2021-05-03 11:36 UTC] cmb@php.net
Is this still an issue with any of the actively supported PHP
versions[1]?

[1] <https://www.php.net/supported-versions.php>
 [2021-05-16 04:22 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 "Re-Opened". Thank you.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Tue Apr 16 12:01:29 2024 UTC