Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

date

Former Member
0 Likes
831

hai all,

i have invoice date records ,based on invoice date i want to reduce the invoice date from last day of that week

what is the logic?

example :

invoice date = 21-01-2008

for this i want to reduce from that week last date i.e 26-01-2008

like this for all invoice records

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
812

Hi Upender,

Plz find the FM GET_WEEK_INFO_BASED_ON_DATE

...you wil get the first n last day of the week for the given date..

Regards,

Kaveri

6 REPLIES 6
Read only

Former Member
0 Likes
812

can u explain clearly

Read only

0 Likes
812

invoice date = 21-01-2008

for this i want to reduce from that week last date i.e 26-01-2008

like this for all invoice records

date = 21-01-2008

month is jan

21 comes under 4th week

in jan month 4th week last date is 26-01-2008 so

i want 2 reduce my invoice date from 26-01-2008

like this for all records

Read only

0 Likes
812

HI,,

use this FM WEEK_GET_LAST_DAY... u can get last day oe the week......

DATE_GET_WEEK Returns week for a date

WEEK_GET_FIRST_DAY Returns first day for a week

RP_LAST_DAY_OF_MONTHS Returns last day of month

FIRST_DAY_IN_PERIOD_GET Get first day of a period

LAST_DAY_IN_PERIOD_GET Get last day of a period

RP_LAST_DAY_OF_MONTHS Determine last day of month

plzz reward if it is usefull.....

Read only

0 Likes
812

Hi Upender,

As far as my understanding , you are trying to find the difference between the dates 26/01/2008 & 21/01/2008.

If this is the case , you can use the fm.

ws_date = 26/01/2008.

ws_date2 = 21/01/2008.

CALL FUNCTION 'HR_HK_DIFF_BT_2_DATES'

EXPORTING

date1 = ws_date

date2 = ws_date2

output_format = '05' " years, months and days

importing

Years = ws_yr " no of years

months = ws_mnth " no of months

days = ws_days." no of days

reward If USeful.

regards,

Chitra

Read only

Former Member
0 Likes
813

Hi Upender,

Plz find the FM GET_WEEK_INFO_BASED_ON_DATE

...you wil get the first n last day of the week for the given date..

Regards,

Kaveri

Read only

Former Member
0 Likes
812

Use this FM: GET_WEEK_INFO_BASED_ON_DATE

Export parameter : boldSundaybold will give u r last week day....

Hope u r problem get solve....

Regards,

Srinivas M