07-12-2012 8:04 PM
I have a7 select option i/p fields(selection criteria) out of which one is mandatory
select op 1 | LTAK-BETYP | |
select op 2 | LTAK-BENUM | |
select op 3 | LTAK-BWLVS | |
select op 4 | LTAK-TANUM | |
select op 5 | LTAK-BDATU | mandatory |
select op 6 | LTAP-NLTYP | |
select op 7 | LTAP-GRETR |
so i have written my query like
Select A B C D
from LTAK
into table lt_ltak
whereBDATU in so_BDATUandBETYP in SO_BETYPandBENUM in SO_BENUMandBWLVS in SO_BWLVSandTANUM in SO_TANUM.
So according the query above if the user gives mandatory field(bdatu) and any other fields from LTAK table it will work...
now the 2nd query
select X Y Z
from LTAP
into table lt_ltap
for all entries in LTAK
where lgnum = LT_LTAK-LGNUM and NLTYP IN SO_NLTYP and GRETR IN SO_GRETR.
My questions: Is the 2nd query correct..
07-12-2012 8:08 PM
Hi,
Yes both your queries will work. Are you facing any problems? Post your code here if you see any problems.
Regards,
Shravan