Jump to content

Building a complex search query


Recommended Posts

I have a rather complex search which I'm not getting to work quite right so thought I'd come here for assistance.

 

Essentially this is what I'm trying to do, any instances of:

(approv* or verific*) and design, which appear withing 100 words of several other keywords.

 

"(approv* OR verific*) AND design AND (keyword1 OR keyword2 OR keyword3)" ~100

 

The above didn't work so I'm not sure if I can build the query I need this way or if I need to explode my head and try regex.

 

Any help appreciated.

 

Edit: interestingly if I remove the ~100 then the search query as it's structured will work. There's obviously some relationship issues here when trying to tell Intella what that word limit actually applies to.

 

Edit again: sorry, I just found the sticky by Jon which breaks it down nicely for me and I have figured out where my issues are.

Link to comment
Share on other sites

Even after reading Jon's very good post I'm still not sure on something, maybe I missed it.

 

Breaking down the complex search I still can't figure out how to use the proximity function when dealing with a phrase?

 

eg I want to find "beat" within 50 words of "here it comes". Using Jon's keyword method I search for both individually, then tag the overlapping so I have only documents which have both, however from here I'm still facing the same issue with not being able to apply a proximity search on a phrase.

Link to comment
Share on other sites

Hi Adam,

 

Because the double quotes need to encase all of the search terms, you cannot have a search phrase within a proximity search. A search phrase would require double quotes around it and you can't have nested double quotes within a proximity search. That said, you can use phrases in keyword or keyword lists to narrow down the results before running a simplified proximity search.

 

You have done the first part correctly (e.g. I want to find "beat" within 50 words of "here it comes". Using Jon's keyword method I search for both individually, then tag the overlapping so I have only documents which have both search terms).

 

Because you cant us a phrase in a proximity search, you need to run your proximity search for 'beat' and one of the words in the phrase e.g. "beat comes"~50. This could return false positives as 'beat' could be within 50 words of another word 'comes' which is not related to the phrase 'here it comes'. Unfortunately this is a limitation but this process will also return hits for 'beat' within 50 words of 'here it comes'.

 

I hope this makes sense.

 

Jon

Link to comment
Share on other sites

Thanks Jon, yes it makes sense and that was the approach I was taking. I'm lucky in this instance that one of the words in the phrase I need is quite unique.

 

Possibility for the roadmap maybe to allow nested phrase proximity searches?

 

Or alternatively if there is anyone on here who is a regex guru may wish to chime in ;)

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

×
×
  • Create New...