Application Development 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: 

Payment Advice creation - BDC for FBE1.

Former Member
0 Kudos

Hi All,

I am creating the Payment Advice using the transaction FBE1. For this BDC has been written.

But inside the transaction FBE1:

Program: SAPMF06A

In the Include: MF06AF00

In the sub-Routine:VERBUCHUNGSAUFRUF (FORM)

Calls the FM: REMADV_SAVE_DB_ALL (with out any exporting parameters)

Because of which it calls the FM: 'REMADV_SAVE_DB' in "IN UPDATE TASK".

And there is a COMMIT WORK statement at the end of this and hence is ASYNCHRONOUS PROCESSING because of which the CALL TRANSACTION comes out even before the actual payment advice creation takes place.

Because of the above ALWAYS the call transaction fails.

Could anyone please give me a solution for this - to make the call transaction success for FBE1.

Regards,

Goutham.

Points will be definitely awarded for each answer.

1 ACCEPTED SOLUTION

Former Member
0 Kudos

Try to use CALL Transaction UPDATE MODE 'S' and see the results.

Syntax :

Call Transaction tcode using bdcdata

mode 'N'

<b>update 'S'</b>

messages into bdcmsgcoll.

if it is not working then paste ur code and i will try to see the issue.

Thanks

Seshu

4 REPLIES 4

Former Member
0 Kudos

Try to use CALL Transaction UPDATE MODE 'S' and see the results.

Syntax :

Call Transaction tcode using bdcdata

mode 'N'

<b>update 'S'</b>

messages into bdcmsgcoll.

if it is not working then paste ur code and i will try to see the issue.

Thanks

Seshu

Former Member
0 Kudos

Hi Seshu,

Thanks for the reply.

Even though we call it using the Update as S: Synchronous and in the standard program it is using Explicit: COMMIT WORK (and NOT commit work and wait) The FM called in UPDATE TASK is being done in Asynchronous mode. By that time the control is coming back to the next statement after CALL TRANSACTION in my program and sy-subrc is set to 1001.

Please let me know if you have further inputs.

Thanks,

Goutham.

0 Kudos

Then BDC Will not work in that case and look for alternative

Check the below link and it may help you

Thanks

Seshu

Former Member
0 Kudos

Hi All,

Solution for BDC on FBE1.

I went into the debugging of the transaction: FBE1 to find the way the Payment Advice Number is being created. This is being created by the Standard FM: REMADV_INSERT exactly in the sub-routine: NUMMER_VERGEBEN (In Line 35). The Payment Advice Number is 16 characters in Length.

1. First 2 characters: Payment Advice Type (This is entered in the initial screen of FBE1 - Pmnt Advice No. Only first two characters of this are taken - 04 in most cases)

2. Next 6 characters: It is the data in YYMMDD format

3. Next 6 characters: It is the TIME HHMMSS (Hours Minutes and Seconds)

4. Last 2 characters: It is the first two characters of the user name.

Because of simultaneous creation of the payment advice numbers, sometimes for a Combination of Company Code (1000 in our case), Payment Advice Account Type (D) and Account Number (Customer from BSEG-KUNNR) There can be more than one entry that might get simultaneously executed within a second (resulting in creation of the same payment advice number and BDC fails) time because of which the BDC is failing and the records are moving into the error session.

As a solution to this a 1 second wait time has been attached so that the records updation differs by a second and the Payment Advice number differs by one number (point 3 above).

Please let me know if further details are required from my side.

Thanks & Regards,

Goutham