on 06-18-2008 6:37 AM
In my report, i hav to compare the input date with QUATERLY date range. ie. Q1 means 1st APril to 30th june, Q2 means 1st july to 30th Sep, Q3 means 1st Oct to 31st Dec and Q4 means 1st Jan to 31st Mar.
How should i set the values and how to compare my input date with the quaters, how to find the Input dates falls in which quarter?
My input is in the Format MM/YYYY !!
Edited by: Padmashree RamMaghenthar on Jun 18, 2008 7:53 AM
Hi,
Use 4 different ranges and compare them in select query.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Padmashree,
Has your problem been solved?
Nayan
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
1-> First create 4 variable , and assing value in YYYYMMDD format.
2-> while comparing convert the input date into same format and you can compare directly.
ex: w-q1 type d value '20080630'.
w_input type c value '06/06/2008'.
w_temp type d .
w_temp0(4) = w_input6(4).
w_temp4(2) = w_input3(2).
w_temp6(2) = w_input0(2).
after directly you can compare w_temp wih w_q1.
w_temp ge w_q1 or w_temp le e_q1.
reward if helpful.
Bye
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
Define 4 ranges for your report initially. Take the value of Q1 to Q4 in diff ranges. Then create a field for date on your selection screen. Check if the date on the sel screen falls in the first range. If yes then its Q1, else continue.
It should work.
Revert back if any queries.
Thanks
Nayan
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Padmashree ,
Use Range Statement.
for example
data: date1 like sy-datum,
date2 like sy-datum,
date3 like sy-datum.
Ranges: s_Q1 for date1,
S_Q2 for date2,
S_Q3 for date3.
s_Q1-sign = 'I'.
s_iQ1-options = 'EQ'.
s_Q1-low = '20080301' . "01.03.2008
s_Q1 -high = '20080631'. "31.06.2008
append s_Q1.
Like this do for Q2 and Q3 also.
and use these ranges according to your requirement
chk this for more details abt Ranges
http://help.sap.com/saphelp_webas620/helpdata/en/9f/dba71f35c111d1829f0000e829fbfe/content.htm
Pls reward if useful.
Thanks
Murugan.B
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
86 | |
10 | |
10 | |
9 | |
6 | |
6 | |
6 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.