Application Development and Automation 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: 
Read only

Fetching data from COOIS Tcode

0 Likes
976

Hello Experts,

I want to fetch data from COOIS tcode in program and display it.

Code-

IF s_werks IS NOT INITIAL.
APPEND VALUE #( selname = 'S_WERKS'
kind = 'S'
sign = 'I'
option = 'EQ'
low = s_werks-low
high = '' ) TO t_parameters.
ENDIF. " IF s_werks IS NOT INITIAL


IF s_begda IS NOT INITIAL.
APPEND VALUE #( selname = 'S_TERST'
kind = 'S'
sign = 'I'
option = 'BT'
low = s_begda-low
high = s_begda-high )
TO t_parameters.
ENDIF. "

wa_tcoa-opcomp_sel = abap_true.
wa_tcoa-layoutid_de = '000000000001'.
CALL FUNCTION 'COIS_SELECT_PARAMETERS_SET'
EXPORTING
it_parameter = t_parameters[]
is_tcoa = wa_tcoa.

* select data from IOC
* read production orders
CALL FUNCTION 'COIS_SELECT_ORDERS_READ'
CHANGING
ct_ioopcomp = t_opcomp_tab[].


When I pass plant only as selection it is working fine, however when i pass Scheduled Start date, it is not returning any data. Can anybody please let me know how pass date to COOIS Tcode?

If I pass same parameters to COOIS Tcode, it is returning values!

Thanks in advance.

0 REPLIES 0