2007 Nov 27 5:41 AM
hi,
iam having the two dates,i have to find the latest of the two dates.how can i go through it.
it is very urgent.
thanks in advance
hi,
iam having the two dates,i have to find the latest of the two dates.how can i go through it.
it is very urgent.
thanks in advance
2007 Nov 27 5:47 AM
Hi Surya,
if first_date > secound_date.
write : 'first_date is greater'.
else.
write : 'second_date is greater'.
endif.
REward if useful
2007 Nov 27 5:49 AM
Hi Surya,
If you have two dates then you can simply compare two dates by using relational operator like GT, LT etc and you can find out the latest date.
Kindly reward points if it is useful.
Regards,
Gopal.
2007 Nov 27 5:52 AM
just check surya..
data: x type i ..
x = d2 - d1.
if x > 0.
write: 'first date is bigger'.
elseif x < 0.
write ' second date is bigger'.
else.
write: ' both are equal'.
endif.
rewards points if usef ull
2007 Nov 27 5:52 AM
Hi,
DATA:dat1 TYPE sy-datum,
dat2 TYPE sy-datum.
DAT1 = SY-DATUM.
DAT2 = DAT1 - 10.
IF dat2 > dat1.
write:/ 'DAT2 is earlier'.
else.
WRITE:/ 'DAT1 is earlier'.
ENDIF.
rgds,
bharat.
| User | Count |
|---|---|
| 3 | |
| 2 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |