cancel
Showing results for 
Search instead for 
Did you mean: 

Error faced while executing URL in SAP Netweaver gateway client

Saritha_K
Contributor
0 Kudos

Hi Experts,

We are facing an issue while passing URL as given in the attachment with error in the conversion routine "CONVERSION_EXIT_EXCRT_OUTPUT".

Please let us know if there exists a sap note to fix the given problem.

Detailed screenshots of the problem have been attached.

Regards,

Saritha

Accepted Solutions (0)

Answers (4)

Answers (4)

Former Member
0 Kudos

Just faced the same problem. From my point of view it is an error in gateway framework. It calls output conversion exit for exchange rate and provides non-character output field as you can see in debugger. If it provided character like output field (as it should do) everything worked fine. You can not change this behaviour by entering a different data type for the property of the entity type.

Did you import the entity type via DDIC structure? This is where it gets the output conversion info from. If you do not import the exchange rate field from DDIC but just add it from scratch the error will not show.

Maybe you can suppress output conversion in the first place, but this is my first day trying it out so I don't have much knowledge about GW or OData.

Regards,

Christoph

Former Member
0 Kudos

Yes, you can disable output conversion programmatically by overriding /IWBEP/CL_MGW_ABS_MODEL->DEFINE like that (makes use of some new ABAP syntax):

METHOD define.
  super->define( ).

* Disable all output conversion since it is buggy
  DATA(lt_type) = CAST /iwbep/if_mgw_odata_re_model( model )->get_entity_types( ).
  LOOP AT lt_type ASSIGNING FIELD-SYMBOL(<s_type>).
    DATA(lo_type) = model->get_entity_type( <s_type>-external_name ).
    LOOP AT <s_type>-properties ASSIGNING FIELD-SYMBOL(<s_property>).
      DATA(lo_property) = lo_type->get_property( <s_property>-external_name ).
      lo_property->disable_conversion( ).
    ENDLOOP.
  ENDLOOP.
ENDMETHOD.

GK817
Active Contributor
0 Kudos

Hey Christoph,

I also believe its a framework issue. i am planning to open a ticket for the standard team to check this.

A big thanks for providing this demo code to suppress the conversion. I have modified it so it disables only exchange rate field & my service works fine.

Regards

Gaurav K

Former Member
0 Kudos

Hi Gaurav,

I am facing same problem at the moment, what's the suggestion you got from SAP? Thanks.

Regards,

Nick

GK817
Active Contributor
0 Kudos

Hi Nick,

I had disabled the conversion for particular field. I did not open a OSS message but i think this issue should be resolved in upcoming SPs.

Regards

Gaurav K

Former Member
0 Kudos

Hi Gaurav,

Thank you very much.

Regards,

Nick

GK817
Active Contributor
0 Kudos

Hello,

I am also facing the same issue.

@Ron - I tried what you described above but it does not work. If i execute conversion function independently, its working fine but when executed through web service, with exact same values/types, it goes for a short dump. What could be the reason?

Thanks

Gaurav K

Former Member
0 Kudos

Hi Gaurav,

If you are testing with SE37, the function will work because the test harness interface is generated appropriately. I would therefore still be checking the property data type in the model because it is most likely an elementary numeric. The logic of the conversion seems to be changing an 'internal' value into a number suitable for list output. You don't necessarily want this to occur in your feed.

Alternatively, decouple this property from ABAP Dictionary, it is that binding that is invoking the conversion exit.

Regards

Ron.


Former Member
0 Kudos

This is the exchange rate conversion function, so I expect that you have an exchange rate element in the entity that is defined as a numeric EDM type - it probably needs to be made a string. The conversion is trying to SHIFT, which cannot be done on an elementary number type.

Regards

Ron.

Former Member
0 Kudos

Hi Saritha,

Can you please give a code snap... if possible.

We might have problem with the data type used.

Thanks

Saurabh Gupta