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: 

WAIT statement used, IDOC output time still same

Former Member
0 Kudos

HI All,

I have created a Zprog to trigger zIDOCs from R/3 to XI.

In my program, multiple idocs of same type are created as the processing is within a loop statement.

Due to this fact 5-6 idocs are created within a second and sent out immediately to XI.

However I want idocs to go to XI in 1 sec intervals, so I introduced the WAIT statem,ent in the loop.

But when I check WE02, again all IDOCS are craeted in the same time(second), so I do not see any time delay.

I wanted to know if theer is a way to introduce REAL DELAY in sending IDOCs from R/3 to XI as currently all my idocs are going out at same time inspite of using WAIT statement.

In my partner profile I have tried the scenatio with Process immediately and also with collect Idocs(packet size 1), but its not helping.

Any suggestions, how to make the idocs leave R/3 witha time delay of 1 sec each between them?

Appreciate any suggestions/pointers.

Many thanks

Shirin

1 ACCEPTED SOLUTION

Former Member
0 Kudos

Shirin

It may be due the Automatic Commit work at the end of program... I would suggest to put commit work and required wait after calling the function module for IDOC Creation...

Thanks

Amol Lohade

7 REPLIES 7

Former Member
0 Kudos

Shirin

It may be due the Automatic Commit work at the end of program... I would suggest to put commit work and required wait after calling the function module for IDOC Creation...

Thanks

Amol Lohade

0 Kudos

Hi Amol,

I have already used commit statement as shown below.

CALL FUNCTION 'DB_COMMIT'.

CALL FUNCTION 'EDI_DOCUMENT_DEQUEUE_LATER'

COMMIT WORK.

However I still have this issue...very strange...not sure why???

Any pointers

Regards

Shirin

0 Kudos

Hello

R u passing control table data EDIDC-CREDAT,

EDIDC-CRETIM..?? Just a query...!!!

Thanks

Amol Lohade

0 Kudos

No, I am not passing these 2 values.

Regards

Shirin

Former Member
0 Kudos

After COMMIT WORK add this


WAIT UP TO 60 SECONDS .

0 Kudos

Hi Swastik,

Will WAIT UP TO 60 SECONDS help and send idocs in 1 sec interval.

I do not want a very long delay between these idocs.

Or is it that wait upto 60 ecs translates to 1 sec internally....just trying to understand.

Appreciate if you could clarify.

Many thanks

Shirin

Former Member
0 Kudos

I have given up on WAIT statement. Have asked 3rd party system to handle this situation.