Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

IDOC DOCMAS Inbound problems

alexey_kozlov
Explorer
0 Likes
1,793

I have to problems with IDOC DOCMAS inbound.

1.    I have DRAW TABLE extended by z-fields, some of them have currency type (CURR).

      The standard inbound interface is going to dump when it is trying to write a string to such a field.

      Function module IDOC_INPUT_DOCMAS, FORM get_seg_drawm:

  IF ls_dntab-datatype NE 'NUMC'.
    IF <fs> IS INITIAL.
    IF NOT ( ( ls_dntab-fieldname = 'AENNR'  )  OR
             ( ls_dntab-fieldname = 'VRLDAT' ) ).
      <fs> = '!'.
    ENDIF.

    I really do not see any reason to do anything with z-fields in this form, but it works so.

   Is it possible to do something with it without modifying SAP-code?

2. The second problem is that I can not find any user-exit in IDOC_INPUT_DOCMAS to fill z-fields by z-segments data.

    So I see only the way to do it only after document is created by IDOC_INPUT_DOCMAS, but I do not like this way.

    Do you know any suitable user-exit or have any idea?

I have to problems with IDOC DOCMAS inbound.

1.    I have DRAW TABLE extended by z-fields, some of them have currency type (CURR).

      The standard inbound interface is going to dump when it is trying to write a string to such a field.

      Function module IDOC_INPUT_DOCMAS, FORM get_seg_drawm:

  IF ls_dntab-datatype NE 'NUMC'.
    IF <fs> IS INITIAL.
    IF NOT ( ( ls_dntab-fieldname = 'AENNR'  )  OR
             ( ls_dntab-fieldname = 'VRLDAT' ) ).
      <fs> = '!'.
    ENDIF.

    I really do not see any reason to do anything with z-fields in this form, but it works so.

   Is it possible to do something with it without modifying SAP-code?

2. The second problem is that I can not find any user-exit in IDOC_INPUT_DOCMAS to fill z-fields by z-segments data.

    So I see only the way to do it only after document is created by IDOC_INPUT_DOCMAS, but I do not like this way.

    Do you know any suitable user-exit or have any idea?

4 REPLIES 4
Read only

Former Member
0 Likes
1,183

Hi, Alexey

In that function module you have an implicit enhancements point, at the beginning  of the function module, where you could fill your segment data.

Regards,

Bruno

Read only

0 Likes
1,183

Bruno,

an implicit enhancements point at the beginning  of the function module is not suitable for this task.

Also user-exit (CALL CUSTOMER-FUNCTION '001') exists before the standard segments processing, but all table structures are clearing in standard segments processing form.

An implicit enhancements point at the beginning  of the function module can be used, but it is the same way that I written (only after document is created by IDOC_INPUT_DOCMAS). The document will be first created without z-fields data, that why I do not like this.

Read only

0 Likes
1,183

Alexey,

Refering to your first point, maybe you could try enhancing FM NAMETAB_GET in order to filter out your fields in the return table (this is fishy, i know ) , just before the validation that rules out non-numerical fields in form get_seg_drawm

Bruno

Read only

0 Likes
1,183

Bruno

I think you could not do such enhancement in FM NAMETAB_GET, because it is a dictionary FM and can be used in very many places.

As a temporary decision I did the following for this problem:

an enhancement in the beginning of FORM get_seg_drawm as a copy of that form with EXIT. on the end. In that copy I have corrected the code to exclude z-fields from the processing.