Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SAP RFC Error: RFC_CONVERSION_FAILURE with message: PRUEFLOS of type RFCTYPE_NUM cannot be converted to type RFC_INT8 #93

Open
wangfei9999 opened this issue Dec 18, 2023 · 1 comment

Comments

@wangfei9999
Copy link

我想将一个长度为11的数字转为C#的long可惜失败了。我尝试转为字符串类型,实际返回的是’010000522694‘,默认开头追加了0,这不是我预期的结果,我想应该是’10000522694‘,请问我该如何操得到想要的结果。

@tom-j-irvine
Copy link

Assuming I'm translating your message correctly, you'll need to parse the value yourself. In SAP and ABAP, the NUMC data type (RFCTYPE_NUM) is character data (string) that is restricted to holding numeric characters. So, after receiving the c# string value, you could use Int64.Parse() or Int64.TryParse() to convert the value to a long, if appropriate.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants