Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Calculating values based on startdate and enddate

Hi Experts,

Calculating values based on startdate and enddate

Example for calculation

Type A : value for week 40 = 1 *3 = 3 and week 41 = 1* 5 = 5

Start date :2017-10-04 ,Enddate:2017-10-13

these dats fall under 40 and 41 week, so week started at middle of the week that is 4th the value should calculate to that weekend i.e 3 days the value should be 1*3= 3,and week end at 13 weekday so that week cal should be 1*5=5 ,

if Startdate and Enddate is in week and don't consider weekend days only we need to calculate weekdays,

if Enddate is on week day ex: 12 oct, the value should be 1*4=4.

fields:

startdate, enddate, value

ex:

startdate = 2107-10-06

enddate  = 2017-10-24

value = 4

Type = A

if we took week :40

value= 1 (days) * 4= 4  (week have 1 days only remaining for week)

if we took week  41

value= 5 (days) * 4= 20  (week  have 5 days  )

if we took week 42

value= 5(days) * 4= 20  (week have 5 days )

if we took week 43

value= 2(days) * 4= 8  (week have 2 days to Enddate )

we need not consider weekends

based on week i need to show all values, can anyone help me out.

please find the attached  excel for your reference

Regards

KK

0 Replies