cancel
Showing results for 
Search instead for 
Did you mean: 

Batch macro fails when no CVCs are present

jeff_dillon
Explorer
0 Kudos

All:

We have a situation that occurs a couple of ties a year but causes us considerable headache when it does.

Every so often, we will have a batch macro run on a selection profile that currently returns no CVCs.  This causes that job to fail.  Even though we can continue our process chain, the entire chain fails on completion, which causes our users to panic.

Is there a way to cause the job to complete successfully if there are no CVCs in the profile?  If there a way to check the profiles with an If statement and branch around them?

Thanks in advance,

Jeff

Accepted Solutions (1)

Accepted Solutions (1)

former_member187488
Active Contributor
0 Kudos

Dear Jeff,

Please consider SAP note 1652517.

Best Regards,

Ada

jeff_dillon
Explorer
0 Kudos

Ada,

This looks like it is fixing our problem.  Thanks very much.

Jeff

Answers (2)

Answers (2)

0 Kudos

Jeff,

Have you considered the option to create a "dummy CVC" to ensure that the Selection profile would always return a CVC.  May not be a feasible per your business process.. would be a work around..

Thanks

Raghu

jeff_dillon
Explorer
0 Kudos

Thanks Raghu.

Looks like we were logging in at the same time this morning.  This was our fallback position, and we do have it in place in one of our Planning Areas.

Hope things are well with you.

Jeff

0 Kudos

Jeff,

Thank You. Things are fine at my end.  It is a small world. Hope things at your end are fine. 

Raghu

rajkj
Active Contributor
0 Kudos

Hi Jeff,

One solution could be using a Z program that can give you number CVC combinations (Reuse the progam /SAPAPO/TS_PSTRU_SE16 that displays the CVC or gives you the count - t.code /SAPAPO/MC62). Create a variant for this Z program and add it as a process variant in your process chain before macro execution step. If CVC count is zero or there is error in Z program execution, your process chain should not execute the macros and come to an end.

Thanks,

Rajesh