I have put a select statement in a function module which takes a lot of time to pick the data as it has got some complex selections in it.
Here is the code:
SELECT DOCNUM STATUS CREDAT CRETIM UPDDAT UPDTIM DIRECT IDOCTP MESTYP
INTO CORRESPONDING FIELDS OF TABLE IT_EDIDC
FOR ALL ENTRIES IN IT_DOC
WHERE DOCNUM = IT_DOC-DOC_NUM AND STATUS = '03' OR STATUS = '16'
AND DIRECT = '1' AND IDOCTP = 'SHPMNT05' AND MESTYP = 'SHPADV' OR MESTYP = 'ZDESADV01'.
Can anyone help me how to simplify it and improve the performance there with?
Your help will be highly appreciated.
Thanking you in advance,
With Kind Regards,