Skip to Content
0
Former Member
Sep 14, 2007 at 02:33 AM

how to get the correct value from check box

67 Views

hi guys,

here is a program to read data from IKPF.

with the user tick on the check box, the program will retrive

corresponding records based on the inventory counted (zstat) status.

however i don't get the correct output with the following selection.

Please advise where is going wrong. Thank you.

IF ph_ncnt = 'X'.

v_zstat1 = SPACE.

ENDIF.

IF ph_pcnt = 'X'.

v_zstat2 = 'A'.

ENDIF.

IF ph_acnt = 'X'.

v_zstat3 = 'X'.

ENDIF.

select awerks bmatnr bcharg aiblnr bzeili agjahr a~gidat

b~menge into table t_data

from ikpf as a

inner join iseg as b

on aiblnr = biblnr

and agjahr = bgjahr

where a~werks in s_werks

and a~lgort in s_lgort

and a~gidat in s_gidat

and a~zldat in s_zldat

and ( a~zstat = v_zstat3 OR

a~zstat = v_zstat2 OR

a~zstat = v_zstat1 )

and a~gjahr = p_gjahr.