#43517 [Opn->Bgs]: String longer then 256 mish-mash
| From: | tony2001@php.net | Date: | Tue, 29 Jan 2008 00:49:51 +0000 |
| Subject: | #43517 [Opn->Bgs]: String longer then 256 mish-mash | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-121690@lists.php.net to get a copy of this message | ||
ID: 43517
Updated by: tony2001@php.net
Reported By: gkplus at gmail dot com
-Status: Open
+Status: Bogus
Bug Type: PDO related
Operating System: MS Win XP32
PHP Version: 5.2.5
New Comment:
Sorry, but your problem does not imply a bug in PHP itself. For a
list of more appropriate places to ask for help using PHP, please
visit http://www.php.net/support.php as this bug system
is not the
appropriate forum for asking support questions. Due to the volume
of reports we can not explain in detail here why your report is not
a bug. The support channels will be able to provide an explanation
for you.
Thank you for your interest in PHP.
Previous Comments:
------------------------------------------------------------------------
[2007-12-06 21:57:57] powszechnie dot znanay at gmail dot com
Similar problem:
#40150 PDO::ODBC Multiple byte letter is destroyed.
Charcter string is destroyed.
------------------------------------------------------------------------
[2007-12-06 13:50:38] gkplus at gmail dot com
Description:
------------
String mish-mash. Character string longer then 256 chars mish-mash at
the end of the string.
ODBC Driver in other application work ok.
Regulary mish-mash on all strings longer then 256.
Reproduce code:
---------------
$dsn = "odbc:DRIVER={Progress OpenEdge 10.1A
driver};HOST=localhost;DB=soja;UID=abc;PWD=xyz;PORT=23900";
$dbh = new PDO($dsn);
$sql = 'SELECT
certyfikaty.nr_certyfikatu,
certyfikaty.zakres,
firmy.nazwa_firmy
FROM PUB.certyfikaty, PUB.firmy
WHERE certyfikaty.id_firmy = firmy.id_firmy;
$stmt = $dbh->prepare($sql);
$stmt->execute();
$stmt->bindColumn(1, $nr_certyfikatu, PDO::PARAM_STR, 16);
$stmt->bindColumn(2, $zakres, PDO::PARAM_STR, 512);
$stmt->bindColumn(3, $nazwa_firmy, PDO::PARAM_STR, 64);
while ($row = $stmt->fetch(PDO::FETCH_BOUND)){
echo "<td>".$nr_certyfikatu."</td>";
echo "<td>".$nazwa_firmy."</td>";
echo "<td>".$zakres."</td>";
echo "</tr>";}
$dbh = null;
Expected result:
----------------
echo "<td>".$zakres."</td>"
---------------------------
Dostawy, monta¿, uruchamianie i serwis systemów i urz¹dzeñ elektroniki
morskiej i l¹dowej oraz systemów i urz¹dzeñ dla s³u¿b komunalnych i
administracyjnych. Przedstawicielstwo handlowe i serwisowe producentów
ww. systemów i urz¹dzeñ. Opracowanie i wykonawanie i wykonawstwo
fotoluminescencyjnych systemów oznakowañ bezpieczeñstwa dla obiektów
l¹dowych i morskich.
Actual result:
--------------
echo "<td>".$zakres."</td>";
----------------------------
Dostawy, monta¿, uruchamianie i serwis systemów i urz¹dzeñ elektroniki
morskiej i l¹dowej oraz systemów i urz¹dzeñ dla s³u¿b komunalnych i
administracyjnych. Przedstawicielstwo handlowe i serwisowe producentów
ww. systemów i urz¹dzeñ. Opracowanie i wykonawanie i wykonawstwo
fotoluminescencyjnych systemów oznakowañ bezpieczeñstwa dla obiektów
l¹dowya8µiKdowych i morskich.
-----------------
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=43517&edit=1