number filtering

If you are experiencing problems with "Everything", post here for assistance.
Post Reply
sk2107
Posts: 385
Joined: Sun Aug 07, 2022 8:48 pm

number filtering

Post by sk2107 »

Hello,

I have this group of files that I categorized by using [Hxxx][Oxxx]; where xxx is values between 000 and 999, in the beginning I though that I need [O000] or [H000] or fixed values like [H003][O005] but later on I found that sometimes I need to use more than or lesser than as a filter (for example the value in H category is more then 005 and in O group less then 003) and valid filter for both categories.

Here are some examples
IMG-20221114-WA0050_[H001][O000].jpeg
IMG-20230213-WA0053_[H001][O012].jpeg
IMG-20230427-WA0023_[H001][O002].jpeg
IMG-20230610-WA0032_[H000][O001].jpeg
IMG-20230924-WA0040_[H002][O001].jpeg
IMG-20231002-WA0041_[H000][O004].jpeg
IMG-20240421-WA0009_[H002][O003].jpeg

Regards
void
Developer
Posts: 19839
Joined: Fri Oct 16, 2009 11:31 pm

Re: number filtering

Post by void »

addcolumn:1;2 regex:\[H(\d\d\d)\]\[\O(\d\d\d)\] INT($1:)>5 INT($2:)<3
sk2107
Posts: 385
Joined: Sun Aug 07, 2022 8:48 pm

Re: number filtering

Post by sk2107 »

thank for your rapid reply.

working perfectly, thanks a lot

Best regards
Jimbo
Posts: 3
Joined: Sat Jun 11, 2016 2:34 pm

Re: number filtering

Post by Jimbo »

OMG!

Thank you so much for this! I was up until 2 am trying to figure out regex's for use in BRU and bouncing all over the place trying to figure things out.

With this, I understand it, it's practical, and I can tweak it for TV show episodes, etc:

Code: Select all

addcolumn:1;2 regex:S(\d\d)E(\d\d) INT($1:)>2 INT($2:)<3
You rock!!
NotNull
Posts: 5961
Joined: Wed May 24, 2017 9:22 pm

Re: number filtering

Post by NotNull »

Quick tip:
To also find single-digit seasons or episodes, like S2E12 and S12E1:

Code: Select all

addcolumn:1;2 regex:S(\d{1,2})E(\d{1,2}) INT($1:)>2 INT($2:)<3
\d{1,2} = 1 or 2 digits
Jimbo
Posts: 3
Joined: Sat Jun 11, 2016 2:34 pm

Re: number filtering

Post by Jimbo »

Very grateful! Thanks!!
:D
Post Reply