Filtering for multiple criteria that match and time difference

Juja

New Member
Joined
Jan 14, 2020
Messages
4
Office Version
  1. 365
Platform
  1. Windows
Hello to all I am new here but need some help.

I searched on this forum but didnt find somethig like i need.
Tried to do what i need with fitering and copy to new sheet then filter againg and copy to new sheet but didnt get what i need.
Need to filter put-aways between 150 peoples to get shorter table that need to be checked.

Need to filter for 5 different criteria to match and 6 would need to be that time beetwen 2 same is less than 60sec.

Something like this:

C1C2C3C4C5C6
Value1Value2Value3Value4Value5V6
1AA1B1C123.1.2020 13:40:35
2BA2B2C223.1.2020 12:30:00
3CA3B3C323.1.2020 13:40:00
1AA1B1C123.1.2020 13:41:20
2BA2B2C223.1.2020 12:35:00
3CA3B3C323.1.2020 13:40:00
1AA1B1C123.1.2020 13:43:00
2BA2B2C223.1.2020 12:35:50
3CA3B3C323.1.2020 13:40:00
1CA3B3C223.1.2020 16:23:00
3BA1B1C224.1.2020 8:11:11
2DA1B3C322.1.2020 11:55:35


And result is this:
New table with only rows where first 5 values are same and 6 value is inside 60 sec difference

1AA1B1C123.1.2020 13:40:35
1AA1B1C123.1.2020 13:41:20
2BA2B2C223.1.2020 12:35:00
2BA2B2C223.1.2020 12:35:50
3CA3B3C323.1.2020 13:40:00
3CA3B3C323.1.2020 13:40:00
3CA3B3C323.1.2020 13:40:00


Don't know if that is possible to create.

Thank you all
 

Excel Facts

What is =ROMAN(40) in Excel?
The Roman numeral for 40 is XL. Bill "MrExcel" Jelen's 40th book was called MrExcel XL.
As long as your dates are valid you could do it by adding an extra column to check for qualifying rows, then filter that to get your results. If your dates are text strings that look like dates, then this will not work.

Using the method below, you could filter column G to show only results greater than 1, then sort as needed.

Book1
ABCDEFG
1Value1Value2Value3Value4Value5V6Results
21AA1B1C123/01/2020 13:40:352
32BA2B2C223/01/2020 12:30:001
43CA3B3C323/01/2020 13:40:003
51AA1B1C123/01/2020 13:41:202
62BA2B2C223/01/2020 12:35:002
73CA3B3C323/01/2020 13:40:003
81AA1B1C123/01/2020 13:43:001
92BA2B2C223/01/2020 12:35:502
103CA3B3C323/01/2020 13:40:003
111CA3B3C223/01/2020 16:23:001
123BA1B1C224/01/2020 08:11:111
132DA1B3C322/01/2020 11:55:351
Sheet13
Cell Formulas
RangeFormula
G2:G13G2=COUNTIFS($A$2:$A$13,A2,$B$2:$B$13,B2,$C$2:$C$13,C2,$D$2:$D$13,D2,$E$2:$E$13,E2,$F$2:$F$13,">="&(F2-"00:01:00"),$F$2:$F$13,"<="&(F2+"00:01:00"))
 
Upvote 0
Hello,

thank you for that, but I can't get it to work.
Meanwhile I tried something to make filtering simple.
Created one more column A1&B1&C1&D1&E1 and filter duplicated value to get what I need.
Only thing is that filtering by time that can't get it to work
 
Upvote 0
Are you sure that your dates and times are in a valid format?

If the data has been copied from an external source then it is highly possible that they are text strings that look like dates.

Click on one of the date and time cells, then press Shift Ctrl and ! together, if the date changes to a decimal number then it is valid (press ctrl z to change it back), if it doesn't change then it is text, in which case then they will need to be converted to make them useful.
The easiest way to do this is to use find and replace (ctrl h) on the date and time column to replace . with /

Once done the formula method that I suggested earlier will work.
 
Upvote 0
I tried manualy enter value in date and time column, but still get some error.
Also replaced , with ; to get correct filter range and values in formula.

1579183497071.png


But this can't get this time filter to work.
I try removed sec and to filter only mins but nothing.
 
Upvote 0
Ok, managed to make something but now again is problem with date value.
1579185256034.png

1579185239560.png
 
Upvote 0
To avoid any translation errors, can you copy a few rows to a blank workbook, then upload it to dropbox or similar?

If you do that I can test the formula with the actaul data format to find the cause of the problem.
 
Upvote 0

Forum statistics

Threads
1,215,710
Messages
6,126,396
Members
449,312
Latest member
sweetfriend9

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