extend Excel formula to filter based on a period

esmarques

New Member
Joined
Oct 27, 2020
Messages
34
Office Version
  1. 365
Platform
  1. MacOS
Hello, would anybody be able to help?
In the table below, how can I filter the results on cells U5, U6and U7 based on the period selected ( start date on cell U1 and end Date on Cell U2)
The column D is where the reference dates....
Any help is welcome.
Thank you

Book1
ABCDEFGHIJKLMNOPQRSTU
1in device referrer date time name postcode email reason travel spare1 spare2 spare3 spare4DistrictMonthStart Date4/1/24
2in75081.149.159.1513/3/249:52:10Markol5 0dw510000TamesideMar-24End Date12/31/25
3in75081.149.159.1516/4/249:35:57CiaraM4 4EE520000ManchesterJun-24
4in75081.149.159.1516/4/249:11:46FreyaSK15 3LH1220000TamesideJun-24Total
5in75081.149.159.1516/4/2419:02:25JonOL5 0QR500000TamesideJun-24Individuals4
6in101195.11.117.26/3/2417:21:46JonOL5 0QR1200000TamesideJun-24Districts2
7in96180.229.9.1666/3/2511:34:31JonOL5 0QR700000TamesideJun-25 artist3
8  
9  
New Data
Cell Formulas
RangeFormula
P2:P9P2=IF(G2<>0,IFERROR(VLOOKUP(G2,'[Vale sign in data analysis.xlsm]PostCodes1'!$A$1:$E$1040000,4,FALSE),IFERROR(VLOOKUP(G2,'[Vale sign in data analysis.xlsm]PostCodes1'!$B$1:$E$1040000,3,FALSE),IFERROR(VLOOKUP(G2,'[Vale sign in data analysis.xlsm]PostCodes2'!$A$1:$E$1040000,4,FALSE),IFERROR(VLOOKUP(G2,'[Vale sign in data analysis.xlsm]PostCodes2'!$B$1:$E$1040000,3,FALSE),"Not found")))),"")
Q2:Q9Q2=IF(D2<>0,TEXT(D2,"mmm-YY"),"")
U5U5=IFERROR(ROWS(UNIQUE(FILTER('New Data'!F2:F9998,'New Data'!$F2:$F9998<>""))),0)
U6U6=IFERROR(ROWS(UNIQUE(FILTER('New Data'!$P$2:$P$9998,'New Data'!$P$2:$P$9998<>""))),0)
U7U7=IFERROR(ROWS(UNIQUE(FILTER('New Data'!F2:'New Data'!F9998,'New Data'!I2:'New Data'!I9998=5))),0)
 

Excel Facts

Is there a shortcut key for strikethrough?
Ctrl+S is used for Save. Ctrl+5 is used for Strikethrough. Why Ctrl+5? When you use hashmarks to count |||| is 4, strike through to mean 5.
How about like this:

Excel Formula:
=ROWS(UNIQUE(FILTER(F2:F7,(D2:D7>=U1)*(D2:D7<=U2))))
Excel Formula:
=ROWS(UNIQUE(FILTER(P2:P7,(D2:D7>=U1)*(D2:D7<=U2))))
Excel Formula:
=ROWS(UNIQUE(FILTER(I2:I7,(D2:D7>=U1)*(D2:D7<=U2))))
 
Upvote 0
How about like this:

Excel Formula:
=ROWS(UNIQUE(FILTER(F2:F7,(D2:D7>=U1)*(D2:D7<=U2))))
Excel Formula:
=ROWS(UNIQUE(FILTER(P2:P7,(D2:D7>=U1)*(D2:D7<=U2))))
Excel Formula:
=ROWS(UNIQUE(FILTER(I2:I7,(D2:D7>=U1)*(D2:D7<=U2))))
Hello, thanks for your reply, but I would still need the other filters/counts that were there before....
 
Upvote 0
Excel Formula:
=ROWS(UNIQUE(FILTER(F2:F7,(D2:D7>=U1)*(D2:D7<=U2)*(F2:F7<>""))))
Excel Formula:
=ROWS(UNIQUE(FILTER(P2:P7,(D2:D7>=U1)*(D2:D7<=U2)*(P2:P7<>""))))
Excel Formula:
=ROWS(UNIQUE(FILTER(F2:F7,(D2:D7>=U1)*(D2:D7<=U2)*(I2:I7=5))))
 
Upvote 0
Solution
Excel Formula:
=ROWS(UNIQUE(FILTER(F2:F7,(D2:D7>=U1)*(D2:D7<=U2)*(F2:F7<>""))))
Excel Formula:
=ROWS(UNIQUE(FILTER(P2:P7,(D2:D7>=U1)*(D2:D7<=U2)*(P2:P7<>""))))
Excel Formula:
=ROWS(UNIQUE(FILTER(F2:F7,(D2:D7>=U1)*(D2:D7<=U2)*(I2:I7=5))))
amazing.... thank you very much
 
Upvote 0
amazing.... thank you very much

The marked solution has been changed accordingly. In your future questions, please mark the post as the solution that actually answered your question, instead of your feedback message as it will help future readers. No further action is required for this thread.
 
Upvote 0

Forum statistics

Threads
1,223,880
Messages
6,175,157
Members
452,615
Latest member
bogeys2birdies

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top