In a discussion titled “Wildcard search” under the Feature category, user2 asks for an easy way to implement wildcard search (e.g., finding “DE322X” by searching “322X”) on their small, closed, local Discourse instance, without allowing data to leave the network. They considered the Algolia plugin but ruled it out due to privacy concerns. rishabh suggests using the Data Explorer plugin to export posts as CSV or write custom queries to search within the local database, ensuring data stays on-premises. user2 notes this solution isn’t practical for their team, as it would require manual CSV exports for each search. rishabh then recommends creating a custom Data Explorer query visible in the UI for easier team access. JammyDodger provides a sample SQL query using regex (~*) to match partial strings in post content, and suggests restricting access to specific groups. They acknowledge that while this works, the ideal solution would be native wildcard search from the main search bar — and thus move the topic to #feature for potential future development.
Is there any (easy) way I could get a wildcard search function working on my discourse?
I run a small closed discourse locally at work. It only has ~10 users so we are not talking post amount like a large community.
I saw this Algolia plugin wich seams like a perfect thing, BUT that means they need to index the forum and we can’t let that data leave the local network.
I want to find stuff like “DE322X” when I search for “322X”
You could run this simple query and then click the CSV button to download all posts. Then, you could search across the exported file using a different program.
Thanks, I will save this for later. Might come in handly
But for this I need the whole team to be able to search stuff and would be a real hassle if everyone needed to dump a CSV file every time to find what they need
Though I appreciate it working from the Search bar is ideally what the OP is after. I’ll slide this over to Contribute > Feature in case there’s more demand for it.