Photo Mechanic Plus > Feature Requests

OR variables during ingest

<< < (2/3) > >>

Kirk Baker:
My thoughts are that this is an interesting direction and I'd be happy to discuss further.

-Kirk

ejhutch:
I'd be happy to help discuss this further. Let me know how you'd like to proceed.

Kirk Baker:

--- Quote from: ejhutch on November 30, 2021, 02:37:11 PM ---I'd be happy to help discuss this further. Let me know how you'd like to proceed.

--- End quote ---

I'd like more scenarios about what is trying to be accomplished and what solutions make sense.

-Kirk

ejhutch:
Ok. I'll take some time to think about it and come up with more scenarios or use cases.  While I do that, can you give me any information about how your regex engine is currently implemented? From what I can tell, it is available for use with entering custom searches of the catalog. Which regex version/flavor do you implement? Is it done in Ruby, or if a different programming language or library, what do you use? Is it accessible anywhere else within PM or PM+? Is my assumption that it is used to process the search string, which is then converted into an SQL query, which is then sent to SQLite to be executed? Or is it done a different way? How much use do you think regex searching gets as a portion of your user base (how popular or desired is it)?

I'm happy that you're intrigued by this, but it could be a huge can of worms to open, as I'm sure you well know, and I'd like to learn more so I can judge how to tailor my suggestions to appropriately limit or expand the scope of the request based on how useful it (or parts of it) could be.

Kirk Baker:

--- Quote from: ejhutch on November 30, 2021, 04:56:34 PM ---Ok. I'll take some time to think about it and come up with more scenarios or use cases.  While I do that, can you give me any information about how your regex engine is currently implemented? From what I can tell, it is available for use with entering custom searches of the catalog.
--- End quote ---

Catalog Search does not support full regex.  It has a few operators (like matching the start or end), but certainly not full regex support.

Find/Find and Replace does offer a 'Grep' option, and it uses the Boost regex system, but it doesn't find over the entire catalog database, it only works with the images that are in the current Contact Sheet.  If the Contact Sheet is a million item Search results, it's not effective at all since it would take ages to access the metadata of all of the images in the process of performing the Find operation.


--- Quote from: ejhutch on November 30, 2021, 04:56:34 PM ---Which regex version/flavor do you implement? Is it done in Ruby, or if a different programming language or library, what do you use? Is it accessible anywhere else within PM or PM+? Is my assumption that it is used to process the search string, which is then converted into an SQL query, which is then sent to SQLite to be executed? Or is it done a different way? How much use do you think regex searching gets as a portion of your user base (how popular or desired is it)?
--- End quote ---

The Catalog system is a client server architecture written mostly in Ruby but all of the client-side UI is managed in C++.
The query parser is written in Ruby and only offers a minor subset of regular expressions.  The query parser produces SQL queries and hands them off to SQLite.

Most of our user base does not understand regular expressions.

All that said, I think using Regexes on the output of an evaluated {variable} is entirely doable (just like it is in the Find/Find and Replace panels), but it has to make sense and not be horrible to parse and execute via Boost's regex system.
 

--- Quote from: ejhutch on November 30, 2021, 04:56:34 PM ---I'm happy that you're intrigued by this, but it could be a huge can of worms to open, as I'm sure you well know, and I'd like to learn more so I can judge how to tailor my suggestions to appropriately limit or expand the scope of the request based on how useful it (or parts of it) could be.

--- End quote ---

If limited in scope to {variables} I'm not expecting huge complications.

I don't know of any database query system capable of handling full regex support that produces sane SQL that would execute in reasonable time.  So let's not go there. ;)

-Kirk

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version