当前位置:网站首页>Problems and solutions related to Chinese character set in file operations in ABAP
Problems and solutions related to Chinese character set in file operations in ABAP
2022-08-10 02:12:00 【Wang Zixi】
In practical projects, especially some system integration projects, we often encounter scenarios where we need to receive and parse the binary stream sent from the remote end.The content of this binary stream may be some binary files, such as files in PDF, JPG and other formats, or may be text files.For text files, we need to restore the binary stream to human-readable text.This is the topic that this article will focus on.
Before starting this step, please be sure to complete the previous chapters:
How to upload local files in binary mode in ABAP report
This pre-chapter uploads a text file to the ABAP server in binary form to simulate a binary stream provided by a remote content provider (Content Provider), the type is xstring. The actual content of these binary streams is some text containing Chinese characters. Our task in this article is to convert these binary streams back into user-readable text, and then print them out.
We create a new text file, enter a Chinese character wang, save the file name as wang-utf8.txt, select UTF-8 for encoding.

The size of this file is shown as 3 bytes.This is in line with our expected behavior, because UTF-8 is an implementation of Unicode, and the Unicode value of a Chinese character ranges from 0X4E00 to 0x9FA5, which requires 3 bytes if UTF-8 is used.
We pass this
边栏推荐
猜你喜欢

Docker interview question 2--get the number of database connections and docker-compose

flask——请求、响应、请求扩展、session、闪现、蓝图、g对象、flask-session

基于Web的疫情隔离区订餐系统

快速响应性智能型/智能响应性聚乙二醇纳米/还原响应型水凝胶的研究与制备

Biotin-Cy2 Conjugate,生物素-Cy2 偶联物_Cy2 生物素偶联物

02|运算符

GBJ1510-ASEMI机器人电源整流桥GBJ1510

有PEG-Biotin参与的(CAS:1778736-18-7)Biotin-PEG4-OH广泛用于分子靶点检测

Win7怎么把控制面板添加到右键菜单

XSS详解及复现gallerycms字符长度限制短域名绕过
随机推荐
【kali-密码攻击】(5.2.1)密码分析:Hash Identifier(哈希识别)
递归 二分查找 冒泡排序 快速排序
惊掉你下巴,程序员编码竟然可以被 996 指数化
Data storage - the C language
Web性能测试模型小结
西安生物素-四聚乙二醇-酰胺-4苯酚 浅黄色半固态
信息化和数字化的核心差异
Biotin-Cy2 Conjugate,生物素-Cy2 偶联物_Cy2 生物素偶联物
unity 报错 Unsafe code may only appear if compiling with /unsafe. Enable “Allow ‘unsafe‘ code“ in Pla
Biotin-Cy2 Conjugate, Biotin-Cy2 Conjugate_Cy2 Biotin Conjugate
移动终端数据业务高安全通信方案研究
Stanford CS143 速通PA1教程
Minimum number of steps to get out of the maze 2
对修饰器的实验支持功能在将来的版本中可能更改。在 “tsconfig“ 或 “jsconfig“ 中设置 “experimentalDecorators“ 选项以删除此警告
【CAS:41994-02-9 |Biotinyl tyramide】Biotinyl tyramide price
【kali-密码攻击】(5.1.2)密码在线破解:Medusa
阿里云混合云管理平台多Region架构
c语言指针练习题
y92.第六章 微服务、服务网格及Envoy实战 -- Envoy基础(三)
-Pickling peanuts-