2006 Dec 04 9:40 PM
SELECTION-SCREEN BEGIN OF BLOCK a1 WITH FRAME.
PARAMETERS: p_monat LIKE zgxmit-zmonat DEFAULT sy-datum+4(2).
PARAMETERS: p_gjahr LIKE zgxmit-zgjahr DEFAULT sy-datum(4).
...
SELECTION-SCREEN END OF BLOCK a1.
Since p_monat has DEFAULT sy-datum+4(2) as above declared,
At some point inthe program ,
SELECT zprctr zgjahr zmonat rpt_loc z500_xmit bal_xmit inc_xmit
FROM zgxmit
INTO TABLE it_tbl_zgxmit
WHERE zprctr IN s_prctr AND
zgjahr = p_gjahr AND
zmonat = p_monat.
also here p_monat is sy-datum+4(2).
I am not getting the value of p_monat value which I have enetered on selection screen.
2006 Dec 04 9:50 PM
Hi Sam,
Did you keep a breakpoint and checked the p_monat value right at start-of-selection and before this <b>select statement</b>? If not, can you do that and see if p_monat is changed some where?
Thanks,
Vivek
SELECTION-SCREEN BEGIN OF BLOCK a1 WITH FRAME.
PARAMETERS: p_monat LIKE zgxmit-zmonat DEFAULT sy-datum+4(2).
PARAMETERS: p_gjahr LIKE zgxmit-zgjahr DEFAULT sy-datum(4).
...
SELECTION-SCREEN END OF BLOCK a1.
Since p_monat has DEFAULT sy-datum+4(2) as above declared,
At some point inthe program ,
SELECT zprctr zgjahr zmonat rpt_loc z500_xmit bal_xmit inc_xmit
FROM zgxmit
INTO TABLE it_tbl_zgxmit
WHERE zprctr IN s_prctr AND
zgjahr = p_gjahr AND
zmonat = p_monat.
also here p_monat is sy-datum+4(2).
I am not getting the value of p_monat value which I have enetered on selection screen.
2006 Dec 04 9:46 PM
What is the type of zgxmit-zmonat?
I tried with following code, It works fine for me.
PARAMETERS: p_monat(2) DEFAULT sy-datum+4(2).Raja T
2006 Dec 04 9:49 PM
Are you getting the value for p_monat in the selection screen?
if yes then at some point before you are selecting the data p_monat is getting cleared.
One more thing you can try is
INITIALIZATION.
p_monat = sy-datum+4(2).
Regards
Kathirvel
2006 Dec 04 9:50 PM
Hi Sam,
Did you keep a breakpoint and checked the p_monat value right at start-of-selection and before this <b>select statement</b>? If not, can you do that and see if p_monat is changed some where?
Thanks,
Vivek
2006 Dec 04 9:50 PM
2006 Dec 04 9:54 PM
2006 Dec 04 10:01 PM
I think your code is OK. Are you sure p_monat is not being cleared out elsewhere? Try putting a watchpoint on it.
Rob
2006 Dec 04 10:04 PM
2006 Dec 04 10:12 PM
Hi Sam
1) You did not answer to this
<b>Are you getting the value for p_monat in the selection screen?</b>
To be more clear -> Is there any value appearing for the parameter in the selection screen when the program is executed.
2) Please post the code until the select query.
The only reason I could presume is that the value getting cleared before the select query.
Regards
Kathirvel
2006 Dec 04 10:20 PM
The select query is in At seelection screen.
I commented that out
and I wrote the same select query after
START-OF-SELECTION.
Now the value is coming what ever entered on the seleciton screen.