Bug #79217 [NEW]: Last character of a UTF-8 string gets messed up
From: steve dot lloyd at gmail dot com
Operating system: Centos
PHP version: 7.3.14
Package: ODBC related
Bug Type: Bug
Bug description:Last character of a UTF-8 string gets messed up
Description:
------------
Last character of a UTF-8 string gets messed up. See stackoverflow URL
in Test Script section. I have tried this with multiple PHP versions.
I have concluded it must be an issue with PHP ODBC functions as it works
fine in other languages (python, isql).
Test script:
---------------
https://stackoverflow.com/questions/59904479/last-character-issue-with-sap-hana-utf8-on-php
Expected result:
----------------
å éè´/ä»åºè被å»ç»
å 任塿¸
å/BOMè被å»ç»
MPN:BOMæ¬å¤´å»ç»
gesp. für Besch./Lager
gesp. für Arb.plan/Stückl
Actual result:
--------------
å éè´/ä»åºè被å»ad
å 任塿¸
å/BOMè被ader
MPN:BOMæ¬å¤´å»ç»
gesp. für Besch./Lager
gesp. für Arb.plan/Stüca
--
Edit bug report at https://bugs.php.net/bug.php?id=79217&edit=1
--
Fix committed: https://bugs.php.net/fix.php?id=79217&r=fixed
Fixed in release: https://bugs.php.net/fix.php?id=79217&r=alreadyfixed
Need backtrace: https://bugs.php.net/fix.php?id=79217&r=needtrace
Need Reproduce Script: https://bugs.php.net/fix.php?id=79217&r=needscript
Try newer version: https://bugs.php.net/fix.php?id=79217&r=oldversion
Not developer issue: https://bugs.php.net/fix.php?id=79217&r=support
Expected behavior: https://bugs.php.net/fix.php?id=79217&r=notwrong
Not enough info: https://bugs.php.net/fix.php?id=79217&r=notenoughinfo
Submitted twice: https://bugs.php.net/fix.php?id=79217&r=submittedtwice
register_globals: https://bugs.php.net/fix.php?id=79217&r=globals
PHP version support discontinued: https://bugs.php.net/fix.php?id=79217&r=phptooold
Daylight Savings: https://bugs.php.net/fix.php?id=79217&r=dst
IIS Stability: https://bugs.php.net/fix.php?id=79217&r=isapi
Install GNU Sed: https://bugs.php.net/fix.php?id=79217&r=gnused
Floating point limitations: https://bugs.php.net/fix.php?id=79217&r=float
No Zend Extensions: https://bugs.php.net/fix.php?id=79217&r=nozend
MySQL Configuration Error: https://bugs.php.net/fix.php?id=79217&r=mysqlcfg
Thread (11 messages)
- steve dot lloyd at gmail dot com
- cmb@php.netBug #79217 [Opn]: Last character of a UTF-8 string gets messed up
- steve dot lloyd at gmail dot comBug #79217 [Opn]: Last character of a UTF-8 string gets messed up
- steve dot lloyd at gmail dot comBug #79217 [Opn]: Last character of a UTF-8 string gets messed up
- cmb@php.netBug #79217 [Opn]: Last character of a UTF-8 string gets messed up
- steve dot lloyd at gmail dot comBug #79217 [Opn]: Last character of a UTF-8 string gets messed up
- cmb@php.netBug #79217 [Opn]: Last character of a UTF-8 string gets messed up
- astrologerrahulgaur at gmail dot comBug #79217 [Com]: Last character of a UTF-8 string gets messed up
- Don2563ckman at gmail dot comBug #79217 [Com]: Last character of a UTF-8 string gets messed up
- Max1967Jordan at gmail dot comBug #79217 [Com]: Last character of a UTF-8 string gets messed up
- timsmith12 at aol dot comBug #79217 [Com]: Last character of a UTF-8 string gets messed up