Closed vanvenj closed 4 years ago
Hi, i just got this problem too ,and what i do is just change the gorfc code below like this
at line 284 result = C.GoStringN(utf8str, length)
change to result = C.GoString(utf8str)
and it works
@hanxueming126 If you create a pull request for this, I will merge it.
I wrote a script to read production order detail and have a problem .
The component material description is a unicode string like "壹贰叁肆伍陆柒捌玖拾一二三四五六七八九十1234567890". The length of the material description is 30 when it is Unicode. But when i call the script below, the result show "壹贰叁肆伍陆柒捌玖拾一二三�". The result was incomplete. When i use pyrfc,the result was complete.
After some testing I have found the length of "MATERIAL DESCRIPTION" field of "COMPONENT" table in BAPI_PRODORD_GET_DETAIL is 40 char. While the length of the material description i haved used is 70 when it is UTF8.
I realize the problem may be caused by the utf8,but i don't know how to fixed it. Any help or advice would be really appreciated. Thank you.
I am using Ubuntu 17.04 64bit.
The code i have used is below: