4 ms·
I only search based on pattern in the filename. So I was using find: -name '*something*' locate: --basename Or to search the cached find output: grep
by brbsix 11y ago
I only search based on pattern in the filename. So I was using find:
-name '*something*'
locate:
--basename
Or to search the cached find output:
grep -P '(?<=/)[^/]*something[^/]*$' find_output.txt
Using modern indexing technologies sounds like a great suggestion. Any idea where to start with this? I don't have much in the way db experience.
- atsaloli 11y agoI would recommend storing the data in Postgres (advanced open source database). See how searching the table compared to using find. You can optimize further by adding indexes. Postgres supports indexing based on regular expressions so that if there are particular regular expressions that you often search for, you can index on that.