Filter SharePoint list to only display items that were created within the past 24h - sharepoint

How to build a list view that will only show items in a list that were created or modified within the past 24/48/... hours.

Edit View and in the Filter section select column, which you want to use for filtering (Created or Modified or both). Then select condition is greater than. And insert formula [Today]-2. The number 2 means number of days you want to use for filtering (number 1 means 24 hours in the past, number 2 means 24 hours in the past,...).
Image of result
Please mark this as answer if it helps you.

Related

Counting, filtering, conditioning command in Excel

I am trying to solve this question. The question is:
A sport store target is to provide at least one employee per 10 customers and at least one administer officer per 10 customers. The store checks those figures running a report on the first Friday of the Month every 30 days.
I have added an example of the data. I am trying to identify the months during which the store failed to achieve those figures?
I would appreciate if anybody can help. please see the picture bellow.
=LET(data,FILTER(A:B,(A:A<>"")*(ROW(A:A)>1)),a,INDEX(data,,1),b,INDEX(data,,2),u,UNIQUE(a),x,--(TRANSPOSE(a)=u),mmlt1,CEILING(MMULT(x,--(b="customer")),10)/10,mmlt2,MMULT(x,--(b="SECURITY")),mmlt3,MMULT(x,--(b="administer officer")),FILTER(u,(mmlt3<mmlt1)+(mmlt3<mmlt2),"all correct"))
I took column A for WEEK_ENDING and B for ROLE
You can replace FILTER(A:B,(A:A<>"")*(ROW(A:A)>1)) with your actual data (without headers).
I than took the unique dates and calculated
the count of "customer` matching the date (mmlt1)
the count of SECURITY matching the date (mmlt2)
the count of administer officer matching the date (mmlt3)
I rounded up the customer count to the nearest 10 and then divided by 10.
Now either of the mmlt2 or mmlt3 values should be larger than the count of mmltq (round up & divided by 10) to meet the conditions.
Finally I filtered the unique dates to the conditions. The result spills the dates where either too little security was available per 10 customers, or too little administer officers.

Power Automate: Send reminder out 3 months in advance

I have a Microsoft List that has a column called Expiration Date (text in format of MM/DD/YYYY) and Point of Contact (text in format of email#domain.com). How do I create a flow that sends an email out to the Point of Contact 3 months in advance?
My idea was to create a scheduled cloud flow that:
Repeats every day
Looks at every row in specific list
Compares if Expiration Date - 3 Months = Today
If True, send email to Point of Contact
I am currently stuck on step 3 to compare the date. I did Subtract from time to subtract 3 months from Expiration Date but now I do not know how to use this value to compare to today's date.
A better approach is to filter the list by using an OData filter. That will result in a list with all the elements you need.
For doing so, you need to specify the "Filter Query" field (in red):
First type
ExpirationDate eq ''
Then, between the quotes, add an expression, and select the functions addDays and utcNow in the following way:
addDays(utcNow(),92,'MM/dd/yyyy')
Please notice the following:
I'm adding 92 days to get the same day three months in advance for today (today is Oct 18th, so I'm looking for Jan 18th). Maybe adding just 90 days would work for you.
If you just want to add 3 to the month, you would need to get today's date to a variable with utcNow('MM') to get only the month, add 3 to it, and then create the expression accordingly.
I'm sorry the UI is in spanish. I'm from Mexico. But it's the same idea.
In the image, it reads "ExpirationDateText" because that's the way I named the field in my example. In your case, "ExpirationDate" should work.

Top 3 Values for Multiple Categories based on hours in a week

I'm working on a charging matrix where project managers can input time to the top three contracts in each category based on a week to week basis. Right now I have a pivot table with the categories (Production, Spares, Development) with multiple contracts that were charged that week. I manually select the top three from each category and copy into a table where I have formulas creating charge numbers for the project managers to use.
The question is, is there a way I can automate selecting the top 3 contracts from each category based on number of hours for that specific week?
Pivot Table & Charging Matrix
You can use LARGE() to get the top 3 (large(data,1) etc)
Then use index() and match() to get the contract names.
I have made a simple example here, but it will not deal with duplicate results in the hours if they are in the top 3...
There are solutions to that already posted.
If I understand you correctly, you want to automate the process of finding the top 3 contracts under each category and then create the charge number based on the results.
You can do so by creating a new pivot table as demonstrated below, put the Category Name and Contract Name in the Rows field, and put the Hours in the Values field, then right click anywhere within the Row Labels column of the pivot table, go to Filter -> Top 10... -> enter 3 in the second field, then you should have the top three contracts for each category.
P.s. You can choose to sort the hours from largest to smallest, and choose NOT to show the subtotals for each category.
Once you have the list, you can enter your formula (I presume you used a formula) in corresponding cells in column H (as in my example) to create the desired charge number.

How to count the amount of times a field appears in a specific 'week' in excel

I have a table:
I've created a new column called Distinct Delivery Week, where I have the weeks 1-52 listed.
I want to create a count function if Week == distinct delivery week, make it so it does a count and returns the Channel category that has the most appearances in each respective week.
For example, if App - Activation Organic appears more often than anything else in Week 1, then it will be returned in a new column next to Distinct Delivery Week
With so many data, it may be helpful if you use a simple PivotTable to count how many times per week does each channel appears, and get TOP 1 per week.
I made a fake dataset kind of like yours:
Then I created a Pivot Table like this:
Fields WEEK and CHANNEL into rows section (first WEEK, second CHANNEL, the order is important)
Again, field CHANNEL into VALUES section (make sure the field does a COUNT operation)
Applied a VALUE FILTER in column CHANNEL --> TOP 10, set it up to show just TOP 1
It's a really easy way to get a list where you can see the channel that appears most per week.
I figured out how to do it using this source.
The formula I used was:
{=INDEX(D1:D74686, MODE(IF(H2:H74686=M2,MATCH(D2:D74686,D2:D74686,0))))}

Adding numeric value based on tickbox in Sharepoint formula

I'm trying to create a simple leave planner application using Sharepoint. I've got the bulk of it working but I'm going back to do edge cases now like Bank Holidays and half days. So I've added a checkbox column and if ticked, I want it to deduct 0.5 from the total value (half-day). The formula that's working for the full days is:
=(DATEDIF(dateFrom,dateTo,"D"))-INT(DATEDIF(dateFrom,dateTo,"D")/7)*2-IF((WEEKDAY(dateTo)-WEEKDAY(dateFrom))<0,2,0)+1
So I just created another two columns called shalfday and ehalfday. If they're ticked then deduct 0.5 from the total (If dates match and both ticked then deduct 0.5 still).
I've tried playing round with things like
-IF([shalfday],"0.5")
and other variants as google results are not being too kind this morning but they're returning #NAME? variables.
Any pointers on the syntax or what I should be looking at?
I would suggest:
-IF([shalfday],0.5,0)
Since you are trying to subtract you should work with integers and not strings (i removed the quotation marks).
I ended up doing this another way. I instead asked the user to specify how many half days were in their leave in another site column and used this suffix in the formula. It also got rid of the validation check to make sure the user wasn't taking two half days on 1 days leave.
New site column called 'Total Half Days' set to number, default value of 0;
Appended to original formula:
-([Total Half Days]/2)+1
Full formula:
=(DATEDIF(dateFrom,dateTo,"D"))-INT(DATEDIF(dateFrom,dateTo,"D")/7)*2-IF((WEEKDAY(dateTo)-WEEKDAY(dateFrom))<0,2,0)-([Total Half Days]/2)+1

Resources