Add business days in start date then subtract 1 business day (Excel) - excel

My count of business days in end date should be, for example, May 30 to May 31 will be 2 days and May 30 to May 30 is already counted as 1 day. My problem with WORKDAY is that it counts the day from May 30 to May 31 as 1 day only.
What I've think of is to subtract the result of WORKDAY with 1 business day to get my desired result. However, with my current formula, I was only able to subtract the result of WORKDAY without concerning the weekends (=WORKDAY(C2,B2-1)).
So for example, column C is June 3 (Friday) and column B is 2. The output of my formula will be June 5 (Sunday) because of the subtraction, I want it to be June 6. How will I do that?
Column B = Duration
Column C = Start Date
Column D = End Date (Formula-based)
Column D:
=WORKDAY(C2,B2-1)
Provide Input
B | C | D
2 | 2016/06/03 |
Desired outcome
B | C | D
2 | 2016/06/03 | 2016/06/06

TRY
=WORKDAY.INTL(C2,B2-1,1)
This will set sat. and sun. as offdays

It is not clear exactly what you want to do.
If you want to do an inclusive count of Workdays from 2016/06/03 to 2016/06/06 then you could just use the NETWORKDAYS function.
If you want to add two workdays to Jun 3, and have Jun 3 count as the first day, to give you the result of Jun 6, then use
=WORKDAY(C2-1,B2)
That takes care of the issue where C2 is not a workday, and you want to count 1 workday as the first workday after C2
Otherwise, your formula should work as written.

Related

Average based on day of the week

I would like to have an overview of averages achieved in column H for each day of the week. The daily Averages should go into smaller table as per below. Thanks in advance.
You can do this, combining AverageIf() and Weekday() function, as in the following example I've created:
A B C
========== = =================
11/10/2021 6 =WEEKDAY(A1,2)=1
12/10/2021 8 =WEEKDAY(A2,2)=1
13/10/2021 5 =WEEKDAY(A3,2)=1
14/10/2021 8 =WEEKDAY(A4,2)=1
15/10/2021 6 =WEEKDAY(A5,2)=1
16/10/2021 4 =WEEKDAY(A6,2)=1
17/10/2021 2 =WEEKDAY(A7,2)=1
18/10/2021 2 =WEEKDAY(A8,2)=1
19/10/2021 6 =WEEKDAY(A9,2)=1
20/10/2021 8 =WEEKDAY(A10,2)=1
Afterwards, I've created the formula:
=AVERAGEIF(C1:C10,"TRUE",B1:B10)
This formula calculates the average of the values in column B for all Mondays in column A.
How does this work?
The Weekday() function calculates the number of the day of the week, based on a switch: when the switch is "2", it sees Monday as 1, Tuesday as 2, ...
The AverageIf() function then:
Checks the column C for the values to be checked
Checks those values against "TRUE"
Calculates the average of the B column for the values, obeying the aforementioned criteria.

IF value in list, perform VLOOKUP and add result

I have a list of employees, a column stating their 'available days multiplier' (eg a full time employee would be 1.0, a part time employee working 4 days out of 5 would be 0.91, 3 days would be 0.80 and so on. The next column calculates the employees available holidays, based on a standard 30 days multiplied by the 'available days multiplier'. See below, with an example formula in brackets :
A B C
1 Name | Available Days Multiplier | Holidays
2 Employee A | 1 | 30 (=30*B2)
3 Employee B | 0.91 | 27
4 Employee C | 0.91 | 27
5 Employee D | 1 | 30
Employees have an option to purchase additional holidays, which I have stored in a separate table containing 'Name' and 'Days'
S T
1 Name | Purchased Days
2 Employee 2 | 5
3 Employee 4 | 3
I would like to amend the formula in column C to not only calculate the holidays based on available days multiplier, but also to look up the list in columns S:T and add on any purchased days, if the employee name is found.
I suspect this could be quite easy with an IF/VLOOKUP combination, but I cannot find the correct syntax. Any help greatly appreciated.
If I have understood correctly, you could use SUMIFS:
=(30*$B2)+SUMIFS($T$2:$T$3,$S$2:$S$3,$A2)
This works by first calculating the number of holidays as you have been doing and then adding any purchased ones.
If the employees name appears more than once in the list, it will add the total sum of purchased holidays to the total.
SUMIFS sums the first range (T2:T3) if the second range (S2:S3) matches the criteria (A2).
Hope this helps. If you need further clarification, please let me know.

SLA COUNT IN EXCEL FORMULA

I'm looking for an excel (Office 2016 packet) formula that count SLA for ticket resolution.
the SLA counter must consider :
1) Monday To Saturday as work day ;
2) Holiday as no working days (must be skipeed as work day);
3) SLA start for ticket generate in workdays during range-time "08:00-20:00" out of this time-range SLA count is "0" ;
4) Output should result as R1= first 24Hours ; R2= from 25 to 48 hours ; R3= from 49 to 72 hours; "Out of Sla" = since 72 hours
Data to count SLA is formatted as below for either for ticket open and closure:
Column N Column O Column P Column Q
"TICKET START DATE" "TICKET STOP DATE" "SLA" "HOLIDAY"
28/4/18 13:30 30/4/18 19:20 2 25/04/2018
28/4/18 13:11 29/4/18 13:11 1 01/05/2018
28/4/18 12:57 28/4/18 12:57 1
I solved point 1) & 2) with NETWORKDAYS.INTL formula using the first column as start_date ; the second column as end_date; 11 as third formula's field to exclude Sunday as workdays; fourth formula's value pointing a column where are listed the "holidays" date .
I could not find a solution for point 3).
It will also appreciate a possible solution for point 4) .
Thank you in advance.
Formula example of above fields :
=NETWORKDAYS.INTL(N15;O15;11;Q16:Q17)
Alessandro.
I've needed to do something similar in the past. Please see the formula below. It will give you the amount of time between working days (Monday-Friday), only taking into account times 8:30am to 5:30pm. Try inserting your specific parameters.
=IFERROR((NETWORKDAYS.INTL(H8,I8,,)-1)*("17:30"-"8:30")
+IF(NETWORKDAYS.INTL(I8,I8,,),MEDIAN(MOD(I8,1),"8:30","17:30")
,"17:30")-MEDIAN(NETWORKDAYS.INTL(H8,H8,,)*MOD(H8,1),"8:30","17:30"),"")
H8 = Start Date
I8 = End Date
8:30 = Start Time
17:30 = End Time

Excel 2010 Sum of Values based on their month value and the current month

I've been looking all over for help with this, but not quite found what I'm looking for.
What I'm trying to do is add up the values of CREDIT (B2:B13) up to the current month and put that value in D2.
A B C D
1 DATE CREDIT TOTAL AS OF TODAY
2 15/01/2015 1000 4000
3 15/02/2015 1000
4 15/03/2015 1000
5 15/04/2015 1000
6 15/05/2015 1000
7 15/06/2015 1000
8 15/07/2015 1000
9 15/08/2015 1000
10 15/09/2015 1000
11 15/10/2015 1000
12 15/11/2015 1000
13 15/12/2015 1000
For example: Lets say the current date is 30th April 2015. Sum all the values in B2:B13 up to today's date based on their date value from the Date column (A2:A13). So D2 should = 4000.
I'm quite new to Excel so please forgive me if this is a stupid question.
Thanks very much in advance for any help.
SUMIF should do the trick (documentation here)
So D2's formula would be:
=SUMIF($A2:$A13,"<"&Today(),$B$2:$B$13)
The first argument is the range you want to test. The second argument is the condition you want to test for. The last argument is the range that you want to add up if the test passes.

Excel find date difference between minimum and maximum date in month

I'm trying to fix up a formula I have that's having some issues. It's supposed to track # days invoiced in a month, so the high-level idea is to take the maximum date in a month and subtract the minimum date in the month, and on error subtract the 1st day of the month. My current formula has issues adjust for invoices that may cross months, an example being 1/25 - 2/3 where if this were the only invoice, January should show 7 days invoiced and February would show 3. If there were another invoice from 2/15 - 2/28, I would want Feb to show the maxed invoice days, 14 in this example.
For reference here's what a table could look like:
A B C D E F
start month end month invoice begin invoice end Month Max Days invoiced
jan 1 feb 1 1/25/14 2/3/14 1/1 7
feb 1 feb 1 2/15/14 2/28/14 2/1 14
3/1
etc.........
I tried the formula below but it was erroring out, plus I don't think it will account for gaps in invoices like in my example.:
=IF(B2:B100=X1,MAX(D2:D100),) - IF(A2:A100=X2,MIN(C2:C100),A2)
'where column X is a list of months, X1 = 1/1, X2 = 2/1, etc.
No luck with this formula either, keeps erroring out and giving 0 values:
{=DATEDIF(IF(A2:A100=E2,MIN(C2:C100),),IF(B2:B100=E2,MAX(D2:D100),),"d")}
I appreciate your help!
Not sure exactly what you are looking for but you could probably make use of the EOMONTH() function. Here's an example of it:
=EOMONTH(A2,0)-A2+1
by the way - here is how you would get the start of the month:
=EOMONTH(TODAY(),-1)+1
Try the following per your comment below:
"I think this could be useful but I'm not sure it would work if the invoice end was, say, 2/21 or anytime before the EOM"
=IF(B3>=EOMONTH(A3,0),EOMONTH(A3,0)-A3+1,B3-A3+1)

Resources