Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.

Spca2014 search queries explained svenson

450 views

Published on

  • Be the first to comment

Spca2014 search queries explained svenson

  1. 1. Search Queries Explained Mikael Svenson –Principal Consultant @mikaelsvenson–mikael.svenson@puzzlepart.com –techmikael.blogspot.com
  2. 2. Dev by day –Super Hero by Night with great power comes great responsibility
  3. 3. I will not cover •Managed property weights •Full-text indexes in detail •Custom rank profiles •Graph Query Language (GQL v1)
  4. 4. I will cover •Overview of components involved in a search page •Crawled and Managed Properties •Keyword Query Language (KQL) •FAST Query Language (FQL) •Result Sources •Query Variables •Query Rules •Orchestration using Content Search Web Part
  5. 5. Overview Web Part Result Source (Scope) Result Type Item Template Control Template Search Index Search Result Web Part CSWP is hard set
  6. 6. Crawled and Managed Properties Column InternalName Title CrawledProperty ows_Title Managed Property Title Column InternalName (taxonomy) MyLocation CrawledProperty ows_MyLocation,ows_taxId_MyLocation Managed Property owstaxidMyLocation Column InternalName (date) ArticleStartDate CrawledProperty ows_ArticleStartDate,ows_q_DATE_ArticleStartDate Managed Property (type text) ArticleStartDateOWSDATE use Date00 / RefinableDate00
  7. 7. What makes a SharePoint column/field searchable? Managed Property Crawled Property
  8. 8. What makes a SharePoint column/field searchable? Crawled Property Managed Property Included inFull text-index Not included inFull text-index Searchable NotSearchable ColumnSearchable x ✓ x ✗ x x ✓ x x ✓ x x ✗ x x ✗
  9. 9. KQL -Demo contoso contosomarketing contosoOR marketing ((contosoOR marketing) OR (sales)) NOT bistro author:julian author:julianauthor:garth author:julianAND author:garth author:garthtitle:sales size:50..100 write:“thisweek" write:"lastmonth" contosoNEAR(2) marketing contosoONEAR(3) marketing marketing ONEAR(3) contoso contosoXRANK(cb=10) marketing
  10. 10. KQL -Demo GP0|#<guid> All items tagged with term GPP|#<guid> All child items of term, but not the term GTSet|#<guid> All terms in term set All Departments owstaxIdDeptTaxonomy:"GTSet|#8ed8c9ea-7052-4c1d-a4d7-b9c10bffea6f" Engineering (only have one level) owstaxIdDeptTaxonomy:"GP0|#c7284168-2c56-460c-bb37-743a62b4ba57"
  11. 11. FQL –It’s all really FQL •More operators •starts-with •ends-width •filter •..http://msdn.microsoft.com/en-us/library/office/ff394606(v=office.15).aspx •Perhaps not for human input •Refinement filters by default are FQL –ranking will be different
  12. 12. FQL Demo –It’s all really FQL •KQL: contosomarketing •FQL: and("contoso", "marketing") •KQL: ((contosoOR marketing) OR (sales)) NOT bistro •FQL: andnot(or(or("contoso", "marketing"), "sales"),"bistro") •FQL: title:starts-with("knowledge") •Perhaps not for human input •Refinement filters by default are FQL –ranking will be different
  13. 13. Result Sources •Think of them as 2010 scopes with sorting powers •What should be included or omitted? •SSA, Tenant, Site Collection, Site Levels •GUIDs change on import for SearchConfigexport/import
  14. 14. Query Variables –web part on page to filter page tag against people •{?} notation –exclude if empty •{} notation –don’t add quotes •{|} notation –multi-value expansion •User •Page •QueryString •Custom ones –inject in page or webpart •User segments -> query rules
  15. 15. Query Rules •Triggering •Rewrite •Reorder –only one •Groups with stop/continue •Result Blocks
  16. 16. Search Orchestration •Create seven result sources (two for triggering) •Create two query rules –above and below the fold •Add result blocks per rule •Edit page, reconfigure CSWP to use above sources •Use asyncfor the below the fold web parts
  17. 17. Summary •You are the conductor! •You are responsible for making the connections between •Column -> cp-> mp-> result source -> query rule -> web part •Result type -> display template -> web part
  18. 18. Turning Business Rules into Query Rules It’s all about..
  19. 19. Q & A

×