Sort PDF data by even and even numbers

Post Reply
lb-creative
Newbie
Posts: 8
Joined: Thu Jan 30, 2020 8:46 pm

Sort PDF data by even and even numbers

Post by lb-creative » Tue Nov 24, 2020 12:17 pm

We have a folder where the PDF files arrive. Now we want to include all PDF data with an even number in a job and all PDF data with an odd number in a job.

Following idea:
The PDF data are marked as follows: ZL-10-Us_059.pdf
or ZL-10-Us_060.pdf

We would now like to include the jobs using "regular expression". We have deposited the following:
First branch (all odd numbers):
\d*[13579]$

Second branch (all even numbers):
\d*[24680]$

Unfortunately this does not work. What are we doing wrong?

Thanks for your help!

laurentd
Member
Posts: 36
Joined: Wed Mar 13, 2019 2:06 pm

Re: Sort PDF data by even and even numbers

Post by laurentd » Tue Nov 24, 2020 12:28 pm

You don't consider the characters before the digits and the extension.
Use .*[13579].pdf$ and .*[24680].pdf$
Laurent De Wilde, Solution Architect @ Enfocus

jan_suhr
Advanced member
Posts: 408
Joined: Fri Nov 04, 2011 1:12 pm
Location: Nyköping, Sweden

Re: Sort PDF data by even and even numbers

Post by jan_suhr » Tue Nov 24, 2020 12:31 pm

Are you testing this with [Job.NameProper]
Jan Suhr
Color Consult AB
Sweden
=============
Check out my apps

lb-creative
Newbie
Posts: 8
Joined: Thu Jan 30, 2020 8:46 pm

Re: Sort PDF data by even and even numbers

Post by lb-creative » Tue Nov 24, 2020 1:51 pm

laurentd wrote:
Tue Nov 24, 2020 12:28 pm
You don't consider the characters before the digits and the extension.
Use .*[13579].pdf$ and .*[24680].pdf$
Great. That's how it works. Thanks a lot!

Post Reply