FoxTrot Search Forum
FoxTrot Search for macOS Forum

Home » Public Forums » FoxTrot Search User Forum » How to do proximity search that include accent marks
How to do proximity search that include accent marks [message #1668] Tue, 20 June 2023 01:23 Go to next message
Atlas
Messages: 130
Registered: August 2009
Senior Member
I use markdown syntax to write code blocks that begin with three back ticks "```". I'm want to search for documents that have the string "```" within 50 characters of the word "find". This is basically a search for code snippets with the "find" command. I've looked at the Foxtrot documentation and I see the syntax for "exact strings", but I can't combine the proximity-search and exact-string-string search together to do what I'm looking for.

Can someone kindly point me in the right direction, or let me know if this search is supported in Foxtrot?

Thank you.
Re: How to do proximity search that include accent marks [message #1669 is a reply to message #1668] Tue, 20 June 2023 09:07 Go to previous messageGo to next message
FoxTrot Engineering
Messages: 385
Registered: April 2020
Senior Member
Proximity search, a.k.a. "neighboring words", is actually that: whole or partial words in the same neighbourhood; thus you can't search for exact strings.
You may consider a regular expression, e.g. something like this:
```.{0,50}find
As usual when using regular expressions, also search for the whole word [find] to first reduce the number of documents where the regular expression is evaluated.


Jérôme - FoxTrot Engineering

[Updated on: Tue, 20 June 2023 13:32]

Report message to a moderator

Re: How to do proximity search that include accent marks [message #1670 is a reply to message #1669] Tue, 20 June 2023 20:15 Go to previous message
Atlas
Messages: 130
Registered: August 2009
Senior Member
Thanks for the help. I have follow-up questions.

1. The approach of using regular expression is perfectly sensible, and I access my regex via Foxtrot Query (because I can use script to write a text string for the query rather than relying on user interface to construct query). In Foxtrot Query, the symbol "`" is used to denote the start of a regular expression. What's the syntax for escaping the "`" in Foxtrot Query?
2. In general, what's the best way to handle strings with accent marks in Foxtrot? The only method I know to search for "accent marks" (I believe Foxtrot has its own definition of what this means) is to use "exact strings", which has its own special syntax and set of limitations. Is there a better way? Foxtrot's index is faster and better in many ways but its handling of "accent marks" is a pain, because in other search systems like HoudahSpot, DevonThink, and Spotlight, I can can treat a string of accent marks just like any other string of words. For example, in Spotlight and Houdahspot, I can search for three back ticks simply by using "```", but in Foxtrot I need a special syntax for it. Foxtrot is a superior search product overall, but please let me know if there's a better way to do this, because I've been using other tools to search my code base, and I would prefer to be able to use Foxtrot as well.
Previous Topic: my recommendation url is disabled,why?
Next Topic: Lost my license code
Goto Forum:
  


Current Time: Fri Jul 12 21:44:48 GMT+2 2024