加入收藏 | 设为首页 | 会员中心 | 我要投稿 李大同 (https://www.lidatong.com.cn/)- 科技、建站、经验、云计算、5G、大数据,站长网!
当前位置: 首页 > 大数据 > 正文

perl – Postgres 9.4beta1中otrs中子例程条目中的宽字符

发布时间:2020-12-16 06:13:36 所属栏目:大数据 来源:网络整理
导读:从Postgres 9.1.2升级到Postgres 9.4beta1后,OTRS 3.3.5停止使用http-error.log中发现的Perl错误,在关闭票证时引发.错误是: Wide character in subroutine entry at […]/Kernel/System.DB.pm line 499 499行如下: if ( !$Self-{dbh}-do( $Param{SQL},unde
从Postgres 9.1.2升级到Postgres 9.4beta1后,OTRS 3.3.5停止使用http-error.log中发现的Perl错误,在关闭票证时引发.错误是:

Wide character in subroutine entry at […]/Kernel/System.DB.pm line 499

499行如下:

if ( !$Self->{dbh}->do( $Param{SQL},undef,@Array ) ) {

似乎Perl脚本在执行查询时失败.

我的Perl版本是v5.16.3.

我搜索了很多但到目前为止还没有解决方案.

解决方法

这是一个警告而不是错误.查看 perldiag给出了解释.

Wide character in %s

(S utf8) Perl met a wide character (>255) when it wasn’t expecting
one. This warning is by default on for I/O (like print). The easiest
way to quiet this warning is simply to add the :utf8 layer to the
output,e.g. binmode STDOUT,‘:utf8’ . Another way to turn off the
warning is to add no warnings ‘utf8’; but that is often closer to
cheating. In general,you are supposed to explicitly mark the
filehandle with an encoding,see open and binmode.

你有utf8编码的字符,其中Perl期望看到字节.您可能需要在数据到达此点之前对其进行编码().

(编辑:李大同)

【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容!

    推荐文章
      热点阅读