-
Notifications
You must be signed in to change notification settings - Fork 289
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
Method GET_VALUE_TYPE of class ZCL_EXCEL_WORKSHEET causes problems when converted value doesn't fit in the import field #320
Comments
The problem here is that the result of an
(e.g. for conversion exit In other cases, when there is no conversion exit present, it seems desired by the author of class For a correction, I would therefore suggest not to import the field-symbol holding the result as parameter to
but instead to pass the reference to the result data object as a changing parameter :
This way, the data reference can be switched in the method In the implementation of
Then, still in the So far for my proposal. Hope it helps. |
Is this issue fixed? |
Not really - the problem ist deeper and will arise again if we face complex/unexpected conversion exits. |
Proposing solution #982.
|
In the demo report ZDEMO_EXCEL33 the table T005T is used to provide the sample data. It has the column SPRAS with the data type SPRAS which is only one character long. For this field the conversion exit CONVERSION_EXIT_ISOLA_OUTPUT is found in method GET_VALUE_TYPE of class ZCL_EXCEL_WORKSHEET. That causes the input value i.e. 'D' to be converted to 'DE'. But as the input value is the template for the value which holds the output of method GET_VALUE_TYPE in method SET_CELL
First we get reference into local var.
CREATE DATA lo_value LIKE ip_value.
ASSIGN lo_value-> TO <fs_value>.
<fs_value> = ip_value.
the result in <fs_value> is again 'D'. That is no problem with German or English. But if the input language is Bulgarian where the SAP language code is 'W' then the conversion exit returns 'BG' which is stored in the Excel file as 'B'. When this value is read back from Excel to ABAP the 'B' will be interpreted as the SAP language code and will result in Hebrew.
Here you can find some SAP language codes: http://help.sap.com/saphelp_nw04/helpdata/en/c1/ae563cd2ad4f0ce10000000a11402f/content.htm
Please let's discuss how we tackle this problem.
The text was updated successfully, but these errors were encountered: