I have done all the research for above question on SAP community and google and then asking it here as I didn't found answers relevant to my problem.
I am using BAPI_PRODORD_GET_DETAIL to extract production order details using this BAPI. In this example it is Header data.
CALL FUNCTION 'BAPI_PRODORD_GET_DETAIL'<br> EXPORTING<br> NUMBER = ordnr<br>* COLLECTIVE_ORDER =<br> ORDER_OBJECTS = WA_OBJ<br> IMPORTING<br> RETURN = RET<br> TABLES<br> HEADER = it_header<br>
I have to pass select-options values like s_aufnr-low and s_sufnr-high to exporting parameter NUMBER in BAPI which is of type BAPI_ORDER_KEY-ORDER_NUMBER. Ordnr is of same type as NUMBER.
I have come across answers where we have to convert s_aufnr to ranges table then loop ranges table but it will give dump as range table and exporting parameter NUMBER have different types.
Here, I have created range table r_aufnr and trying to pass values to parameter Ordnr having same type as NUMBER parameter in BAPI for export but getting error as The type of "R_AUFNR" cannot be converted to the type of "ORDNR"
Please provide solution for this as I want to pass select-options range for low and high values and extract data for those ranges.
If single aufnr value is entered it works fine. issue is for ranges,
Thanks,
Pravin.