#38972 [Fbk->Opn]: OCI-Lob->loa return broken character

From: Date: Wed, 27 Sep 2006 09:56:37 +0000
Subject: #38972 [Fbk->Opn]: OCI-Lob->loa return broken character
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-102799@lists.php.net to get a copy of this message
ID: 38972 User updated by: masui at emplex dot co dot jp Reported By: masui at emplex dot co dot jp -Status: Feedback +Status: Open Bug Type: OCI8 related Operating System: linux PHP Version: 5.2.0RC4 New Comment: Yes, I set ".AL32UTF8" to NLS_LANG. My CLOB data in Oracle is "Zˆê“ñŽOŽlŒÜ˜Z޵”ª‹ã". Broken is only 64bit Linux only, 32bit linx is ok. Previous Comments: ------------------------------------------------------------------------ [2006-09-27 09:15:34] tony2001@php.net Cannot reproduce. Make sure your NLS_LANG is set and equals to something similar to ".AL32UTF8". ------------------------------------------------------------------------ [2006-09-27 07:59:54] masui at emplex dot co dot jp Description: ------------ OCI-Lob->load returns broken character or nothing in php 5.2.0RC4. It is occurred in 64bit linux, in 32bit linux OCI-Lob->read returns correct multibyte string. My Oracle database is R10.2.0.2.0, charset is AL32UTF8. Downgrading to php 5.2.0RC1, it works correct, so this might be bug. Best regards Hideaki Masui Reproduce code: --------------- $conn = oci_connect('scot', 'tiger', 'xxx'); if (!$conn) exit; $query = 'SELECT LOBDATA FROM LOBTEST'; $stid = oci_parse($conn, $query); if (!$stid) exit; $r = oci_execute($stid, OCI_DEFAULT); if (!$r) exit; while ($row = oci_fetch_array($stid, OCI_RETURN_NULLS)) { echo $row['LOBDATA']->load() ."\n"; } oci_close($conn); Expected result: ---------------- The "echo $row['LOBDATA']->load();" line should return the actual mulitibyte string from the select statement. Actual result: -------------- $row['LOBDATA']->load() returns broken character or nothing. ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=38972&edit=1

« previous php.bugs (#102799) next »