0

I would like some help to figure out what these Regular Expression rules in search Query means, or could anyone link me resources related to Regular Expressions for Sharepoint 2013 Search?

1) (?^|[^#][\s])#(([[]])|('['])|(?[\w]))(?.*)

2) ((^(?!(([\d-.\s()+]*([a-df-su-wyzA-DF-SU-WYZ]+|[tT]|[eE](?|[xX][a-zA-Z]+)[eExXtT]+.?\s?(?\d+)?$)|(^(?=(+|00|0)(\d{4,-})$)(")?(+|00|0)(?\d+)(")?$)

3) (^(?:(?![:=]).)+$)

0

You can always test with examples to try to understand the RegEx. I often use an online RegEx tester for this, for example https://www.regex101.com/.

Here there is a list of operators for search RegEx in Sharepoint 2010. They will be that same for 2013 and most likely are the exact same ones as the standard RegEx syntax:

http://blogs.msdn.com/b/enterprisesearch/archive/2010/01/21/regular-expressions-support-in-crawl-rules.aspx

0

I am not a RegEx expert. I don't know what #1 is, but #2 Is a Phone Number match on the "Local People Results" Result Source and #3 Is an Expertise Match on the "Local People Results" Result Source.

For any of these rules you can use the Query Rule tester built into the Manage Query Rules page. Select a Context and then enter a query like "512.555.1212" and you will see the following in the test results. It shows how your query is applied. enter image description here

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.