SAP for Utilities Discussions
Connect with fellow SAP users to share best practices, troubleshoot challenges, and collaborate on building a sustainable energy future. Join the discussion.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Posting statistical debit item in mass write off process FP04M

ankit_munshi2
Participant
0 Likes
1,283

Hi,

We have a requirement for which the solution proposed involved posting a statistical debit item during write off process. So we enhanced event 5040 to post item there (called function module ISU_S_FICA_DOC_CREATE).

Now this solution is working fine for single write off process, but for mass process FP04M, we get an error - function modules called in incorrect sequence.

Is this a known problem? Is there any configuration that we may be missing ?

Any help would be appreciated!

Regards,

AM

7 REPLIES 7
Read only

william_eastman
Product and Topic Expert
Product and Topic Expert
0 Likes
879

Ankit:

I would not recommend that approach.  SAP provides doubtful and IVA process for managing these scenarios. Beyond that you should only use bapis.

regards,

bill.

Read only

Former Member
0 Likes
879

Hi Ankit ,

                   we have a similar development for write-off , we use BDC of FPE1 to post a statistical debit items , i think  you need to recheck how you have implemented the function module in event 5040 .

Although the only issue we have faced with our approach is that some times the line items are written off perfectly but the posting of debit line items has not happened (may be due to user authorizations for posting document missing for certain account class etc) ,  it increases the post processing time as we need to take care that all CA  where items were written off a debit line item  must be posted .

would advise you to add a error message to the application log of the mass process to identify such cases or develop a report to check the amount written off and the amount posted .

Read only

0 Likes
879

You cannot reliably use BDC with ISU, especially in mass activity processes.

Read only

0 Likes
879

Hi,

Thanks for your response.

Did you run BDC inside FQevent or as a separate object ?

Regards,

AM

Read only

0 Likes
879

Hi ,

        we have run BDC inside fqevents .(event 5040)

Read only

AmlanBanerjee
Active Contributor
0 Likes
879

Hi Ankit,

Try using the FM FKK_CREATE_DOC in event 5040.

I think using this FM in write-off mass process, FP04M will not create any issues.

Hope it helps.

Thanks,

AB

Read only

0 Likes
879

Thank you all for your response.

I tried to use ISU_S_FICA_DOC_CREATE / ISU_FICA_DOC_CREATE and BAPI_CTRACDOCUMENT_CREATE . All of these eventually call function module FKK_CREATE_DOC.

The very first code line inside this function module is

IF    I_UPDATE_TASK EQ MEM_UPDAT
     AND   I_RESOB       EQ MEM_RESOB
     AND   I_RESKY       EQ MEM_RESKY
     AND   I_TEST        EQ SPACE
     AND ( I_FKKKO-FIKEY EQ SPACE AND MEM_FIEXT EQ SPACE OR
           I_FKKKO-FIKEY NE SPACE AND MEM_FIEXT NE SPACE    ).


...

..

ELSE.
       MESSAGE E174.
     ENDIF.


In my case MEM_RESOB and MEM_RESKY values (populated from config table TFK090A probably) are populated but i_resob and i_resky values are blank (as these parameters are not passed through import parameter.


Error E174 is thrown thereby. if we try to reset MEM_RESOB and MEM_RESKY values it gives a short dump due to nested call of perform ON COMMIT.


Any idea what we could be missing here?


regards,

AM