‎2007 Apr 18 8:16 AM
SELECT-OPTIONS:s_datbg FOR vttk-datbg OBLIGATORY .
SELECT-OPTIONS:s_tplst FOR vttk-tplst OBLIGATORY .
SELECT-OPTIONS:s_route FOR vttk-route.
SELECT-OPTIONS:s_tdlnr FOR vttk-tdlnr.
SELECT-OPTIONS:s_shtyp FOR vttk-shtyp.
SELECT-OPTIONS:s_vsart FOR vttk-vsart.
i need to validate all the above fields in at selection-screen event but i want to hit the vttk table only once is there any way of doing it.
‎2007 Apr 18 8:18 AM
HI..,
that depends on your requirement..
<b>select *
from vttk
into wa_vttk
up to 1 rows
where datbg in s_datbg and
tplst in s_tplst and
route in s_route and
tdlnr in s_tdlnr and
shtyp in s_shtyp and
vsart in s_vsart.
if sy-subrc ne 0.
message 'Data not found' type 'E'.
endif.</b>
regards,
sai ramesh
‎2007 Apr 18 8:20 AM
hi,
Simiarly do it for other fields too.
tables : vttk.
at selection-screen.
select single * from vttk into vttk where datbg in s_datbg.
if sy-subrc <> 0.
message e100 ...
endif.
‎2007 Apr 18 8:23 AM
HI,
u can validate combination of all fileds by hitting only once. if u want to validate the existence of each and every field u have to hit one time for each field.
so depending on your requirement u can code your program.
‎2007 Apr 18 8:37 AM
ur answers doesnt help me because i need to validate and check for field existence, so if i use select st for each and every field then peroformance issue occcurs