‎2010 Oct 04 10:47 AM
Hi all,
I am using FM CO_ZA_AVAILABILITY_CHK_ORDER to perform ATP check based on order number, but for any order number that I test I am getting the same error stating "No Material component pr PRTs exist". Transaction CN22 also uses the same FM to perform the ATP check, in that case it is working but when I am using the same FM it is not working for me.
Do I need to use the FM in conjunction with any other FM's. Please advise
‎2010 Oct 04 11:01 AM
‎2010 Oct 04 12:00 PM
Hi,
thanks for the reply but this FM is not applicable to my scenario.
‎2010 Oct 04 1:16 PM
‎2010 Oct 04 1:41 PM
Hey Pawan.. thanks for the update ... but will this BAPI be useful in my case .. as I am trying ti get ATP for material under a activity under a network ID ?
I mean I need to check ATP based on an AUFNR (order num.)
Edited by: Premal Mistry on Oct 4, 2010 6:11 PM
‎2010 Oct 04 1:47 PM
Hi,
try to set a breakpoint in the FM: CO_ZA_AVAILABILITY_CHK_ORDER
and look into the parameters wich will set by CN22 (is this the tcode you use??).
Compare this values with your function call.
Hope it helps.
regards, Dieter
‎2010 Oct 04 1:59 PM
I tried that approach.. but it seems that this FM cannot be called individually as it requires some internal table data, which won't be available if I call it individually ...
The system basically reads the order header (CAUFV) and then passes it along with other data to the FM in question ....
I have emulated the same thing in my code but I am not getting the result which I get in CN22/CN23 ...
I suppose there are some specific FM's that one needs to call before calling FM CO_ZA_AVAILABILITY_CHK_ORDER.
‎2010 Oct 04 2:09 PM
Hi,
i think you are right.
If you sook into the FM you can see that are some IMPORT-call from the memory, and
this memory isn't fillend, if the FM is called via SE37 or your own Report.
Regards, Dieter
‎2021 Apr 28 12:52 PM
In case this problem is still relevant for anyone after > 10 years: use FM CO_SF_CAUFVD_GET to fill the structure caufvd_imp for FM CO_ZA_AVAILABILITY_CHK_ORDER.
This works perfectly for me.