gpt4 book ai didi

xml - 向 OTRS 发送带有变音符号的 Soap-Request

转载 作者:塔克拉玛干 更新时间:2023-11-03 01:25:44 25 4
gpt4 key购买 nike

因此,我正在尝试在 CentOS Linux 服务器上向 OTRS 发出 SOAP 请求。有人为此在 Oracle 数据库中制作了一个 PL-SQL-Package,它工作正常,除非数据中有变音符号 (Ü)。

这是我在 linux 错误日志中得到的错误:

Feb 17 08:32:26 eotrs2 GenericInterfaceProvider-10[11317]: [Error][Kernel::GenericInterface::Debugger::DebugLog][Line:218]: DebugLog error:  Summary: Error deserializing message:not well-formed (invalid token) at line 1, column 528, byte 528 at /usr/lib64/perl5/vendor_perl/XML/Parser.pm line 187.  Data   : No data provided.
Feb 17 08:32:26 eotrs2 GenericInterfaceProvider-10[11317]: [Error][Kernel::GenericInterface::Debugger::DebugLog][Line:218]: DebugLog error: Summary: Request could not be processed Data : Error deserializing message:not well-formed (invalid token) at line 1, column 528, byte 528 at /usr/lib64/perl5/vendor_perl/XML/Parser.pm line 187..
Feb 17 08:32:26 eotrs2 GenericInterfaceProvider-10[11317]: [Error][Kernel::GenericInterface::Debugger::DebugLog][Line:218]: DebugLog error: Summary: Returning provider data to remote system (HTTP Code: 500) Data : Error deserializing message:not well-formed (invalid token) at line 1, column 528, byte 528 at /usr/lib64/perl5/vendor_perl/XML/Parser.pm line 187..

在我们拥有 PL/SQL 包之前,我们在同一台服务器上使用了 Perl 脚本,而 OTRS 服务正在使用 SOAP::Lite 运行。激活此 Perl 脚本中的跟踪,我意识到,它只是将我提供的 XML 文件中的变音符号“Ü”更改为 SOAP 请求中的“Ã�”,这显然也不正确。

Oracle 数据库上的

NLS_CHARACTERSETAL32UTF8otrsNLS_LAN - 服务器上的用户是German_Austria.utf8

有什么建议吗?

最佳答案

我找到了一个不太令人满意的解决方案。

在 PL/SQL 过程中,我使用

l_envelope := CONVERT(l_envelope, 'AL32UTF8', 'WE8ISO8859P1');

这意味着,我将其转换为 ISO 8859-1。但这并没有回答我的问题,为什么它需要这个字符集。我们通常使用UTF-8。

关于xml - 向 OTRS 发送带有变音符号的 Soap-Request,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/35450689/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com