on 02-12-2008 10:01 AM
Hi All,
Having doubt in ranges ?
im having variable date1 which carries value sy-datlo.
for ex : 12.02.2008
My requirment is i want date that shoul be exactly less than 1000 days by the current system date(date1)
Regards,
Murthy
Hi,
date1 = sy-datum - 1000.
Plzz reward points if it helps.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
hi Murthy,
do this way
data: date like sy-datum,
date1 like sy-datum.
date = sy-datum. " here pass ur i/p
CALL FUNCTION 'RP_CALC_DATE_IN_INTERVAL'
EXPORTING
date = date
days = 1000 "days to be added
months = 00
SIGNUM = '-' "add(+) or substract(-)
years = 00
IMPORTING
CALC_DATE = date1. " new date
write:/ 'new date', date1[/code].
pass the i/p as a parameter
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
hi,
First convert your date to local format using fm 'CONVERT_DATE_TO_INTERNAL' , then subtract 1000 from that again convert date to external format using fm 'CONVERT_DATE_TO_EXTERNAL'.
Rgds,
Bujji
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
CALL FUNCTION 'DAYS_BETWEEN_TWO_DATES'
EXPORTING
i_datum_bis = sy-datum
i_datum_von = date1
IMPORTING
e_tage = lv_day
EXCEPTIONS
days_method_not_defined = 1
OTHERS = 2.
IF sy-subrc EQ 0.
IF lv_day > '1000'.
* show eror message
ENDIF.
ENDIF.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
You can make use of FM CALCULATE_DATE. (By using this FM you can increase or decrease no. of days from the given date).
Thanks,
Sriram Ponna.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
use this FM
HR_SEN_CALE_DAYS_DATE
Import parameters Value
ID_DATE 10.02.2008
ID_OPERATOR -
IS_DURATION 0.0000 0.0000 1,000.0000
Export parameters Value
ED_DATE 17.05.2005
Cheers,
jose.
Edited by: jose on Feb 12, 2008 11:08 AM
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
94 | |
9 | |
9 | |
5 | |
4 | |
3 | |
3 | |
3 | |
3 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.