SlideShare ist ein Scribd-Unternehmen logo
1 von 33
KQL AND THE CONTENT
SEARCH WEB PART (CSWP)
IT Pro Solutions leveraging SharePoint 2013
search abilities (and KQL,REST and jQuery).
ABOUT ME: PAUL MCCOLLUM
SharePoint Platform Manager at 7-Eleven Inc.
MCITP SharePoint 2010, MCTS SQL Server, SP 2007,WSS
@SharePointShark (www.sharepointyesNO.net)
Programming since 1978
Technology Evangelist/Forecaster
www.everythingUSB.com
www.ohGizmo.com
Solution Architect
JavaScript sub-guru
Intranet Platform Manager/Governance/Solution Architecture
{paul_mccollum}AT{Hotmail}
LEANING INTO A NEW ERA
 Content Creation Explosion
 The ease of SharePoint turned many people and businesses into
content publishing machines.
 And in many cases the machines turned into monsters.
 People didn’t understand Content Governance.
 Search is similar.
 Due to the technology of the time:
 Content loading was slow
 Search was SLOWER and resource intensive.
 No need for concepts like tagging or SEO.
BUT…
 We still handle search with tongs like we are worried it's going to
break again.
 There's usually ONLY:
 A search page.
 A search box.
I’m so
lonely.
WHY AREN’T WE LEVERAGING
SEARCH MORE?
 Since search data is cached well, the heavy lifting is done by the
crawl.
 Search queries can actually be more performant than those from
native data.
 This gives us a reason to take a second look at content we
surface and see if it could be improved with search data.
 With FAST Search in SharePoint we can now look at Search as a
Primary Data Source
CONTENT SEARCH WEB PART
 The Content Search Web Part is one of the easiest ways to start
“turning the corner” to grab and correlate data to provide more
useful information to the user.
 With CSWP you can very easily coalesce topic based information
and not be as worried about the source or physical location of
the data.
 Currently working in o365 (November 2013)
CSWP, KQL AND DISPLAY TEMPLATES
 Now that we see a little bit of the technology change, we can start
to look at making use of it to power mini-applications.
 Content Search Web Part
 Simple and Wizard driven.
 KQL
 A pseudo-language and syntax to refine search queries beyond the Wizard.
 No more CAML
 Display Templates
 HTML formatting, no XSLT
 Can be extended with JavaScript and jQuery.
 REST Connectors
 Use as a raw data source for apps
 No more CAML
OUT OF THE BOX,
IT LEAVES A LOT TO BE DESIRED.
HOWEVER, THE QUERY WIZARD IS
PRETTY AWESOME
CSWP : EXAMPLES
 Demo: Create CSWPs
CSWP : EXAMPLES
CSWP : VS. WMS
 WMS (Work Management Service)
 Limited
 Fast
 Tied to User Profile, Search and WMS Services
 CSWP
 Flexible
 Predictable
 Only dependent on Search Service
KQL
 KQL: The language of Search
 2 types
 Keyword
 Generic word search
 Word or Words
 "a phrase“
 * wildcard: works for words but only for the end of phrases
 Property Filter
 Targeted and Refined for specific columns or metadata
KQL
 Property Filtering (syntax)
 Author equals “John Smith”
 <Property Name> <Property Operator> <Property Value>
 author:"John Smith"
 secondaryfiletype:docx
 filename:budget.xlsx
 Property Names must be Managed Fields in SharePoint
 Unmanaged fields must be registered to show up in Search (Huge list available by
default)
 Property Operators
 (numeric, int, DateTime) : = < > <= >= <> ..
 (string/bool) : =
 Other Operators
 UNION AND (+) OR NOT (-) NEAR ONEAR
KQL
 Variables (from requestor context)
 {Site.URL}
 {Site.<property>}
 {Page.URL}
 {URLToken.<integer>}
 {User.Name}
 {User.Email}
 {User.<property>}
 Many more…. https://technet.microsoft.com/en-
us/library/jj683123.aspx
KQL
 Attributes (from result set)
 https://technet.microsoft.com/en-us/library/jj219630.aspx
KQL
 Demo of KQL and config of CSWP
 THEN *Audience Participation*
EXAMPLES
 Is my stuff getting old?
 Author={User.Name}
LastModifiedTime<{Today-65}
 What have I been working on this week?
 Author={User.Name}
LastModifiedTime>{Today-5}
 My ears are burning. Who’s talking about me?
 Author<>{User.Name}
AND
( {User.LastName} OR {User.Email} )
 Who’s messing with my Stuff?
 Author={User.Name}
ModifiedBy<>{User.Name}
 Manage My Content
 These files are too big.
 Size>30000000
 These files should only be on certain sites.
 (SecondaryFileExtension=wmv OR
SecondaryFileExtension=avi OR
SecondaryFileExtension=mpg OR
SecondaryFileExtension=asf OR
SecondaryFileExtension=mp4 OR
SecondaryFileExtension=ogg OR
SecondaryFileExtension=ogv OR
SecondaryFileExtension=webm)
 These words really shouldn’t be on the site.
 “Damn” “heck” “chick” “credit card” “SSN”
 What’s new in HR this week?
 path:"http://SITE/HR/"
(IsDocument:"True" OR
Contentclass:"STS_ListItem")
LastModifiedTime>{Today-5}
 Governance
EXAMPLES: BONUS ROUND
 (
 SecondaryFileExtension=jpg
 OR SecondaryFileExtension=gif
 OR SecondaryFileExtension=bmp
 OR SecondaryFileExtension=png
 OR SecondaryFileExtension=tiff
 OR SecondaryFileExtension=raw
 )
 “Mud” “soil” “earth”
USEFUL ALONE OR IN GROUPS
DISPLAY TEMPLATES : MECHANICS
Display Templates are very similar to the
CQWP XSLT templates.
An Outer Template calls a looping Inner
Template.
No longer XML and XSLT
HTML and JavaScript with ‘Server Side’
Substitution
DISPLAY TEMPLATES : MECHANICS
To Access Display Template
• Map Network Drive
• Don’t need Designer
DISPLAY TEMPLATES : CODE
Result Variable Column Mapping
DISPLAY TEMPLATES : CODE
Variable Assignment
Display HTML
DISPLAY TEMPLATES : EXAMPLES
Demo of Display Template alterations
THE REST: WITH REST AND JQUERY
HTML vs .Net
Document Library
Versioning
No Compilation
Content Editor Web Part
Script Web Part
Cloud Friendly
THE REST: WITH REST AND JQUERY
REST, HTML and jQuery
More Power
More Flexibility
Fewer Hoops
THE REST: WITH REST AND JQUERY
 Learning REST
 POST or GET
 Chrome’s Dev HTTP Client
 Fiddler
THE REST: WITH REST AND JQUERY
jQuery
Ajax
JSON
.each()
THE REST: WITH REST AND JQUERY
Places to get ideas
DynamicDrive.com
JavascriptKit.com
Smashingapps.com
THE REST: WITH REST AND JQUERY
Steps
Create query URL (REST)
Load into Array
Convert to HTML structure (if needed)
Wire-up to flashy plugin
JQUERY APPS : EXAMPLES
 Demo: Create REST Search mini App
RESOURCES
 KQL
 http://msdn.microsoft.com/en-us/library/sharepoint/ee558911.aspx
 http://msdn.microsoft.com/en-us/library/jj163973.aspx
 Search Variables
 http://technet.microsoft.com/en-us/library/jj683123.aspx
 Default Crawled Properties
 http://technet.microsoft.com/en-us/library/jj219630.aspx
 Display Template Reference
 http://technet.microsoft.com/en-us/library/jj944947.aspx
 http://msdn.microsoft.com/en-us/library/jj945138.aspx
 Codeplex sharepoint query tool.
 REST Endpoints
 http://msdn.microsoft.com/en-us/library/office/apps/jj860569.aspx
 REST Programming
 http://www.plusconsulting.com/blog/2013/05/crud-on-list-items-using-rest-services-jquery/
 SharePoint Search REST API overview (http://server/_api/search/query?querytext='sharepoint')
 http://msdn.microsoft.com/EN-US/library/sharepoint/jj163876.aspx
 Working with Result data from REST calls
 http://sharepointfieldnotes.blogspot.com/2013/01/sharepoint-2013-search-with-rest-app.html
 Image Rotator
 http://www.dynamicdrive.com/dynamicindex14/shockwave/index.htm

Weitere ähnliche Inhalte

Was ist angesagt?

Building SharePoint Single Page Applications Using AngularJS
Building SharePoint Single Page Applications Using AngularJSBuilding SharePoint Single Page Applications Using AngularJS
Building SharePoint Single Page Applications Using AngularJS
SharePointInstitute
 

Was ist angesagt? (20)

React & GraphQL
React & GraphQLReact & GraphQL
React & GraphQL
 
How web works and browser works ? (behind the scenes)
How web works and browser works ? (behind the scenes)How web works and browser works ? (behind the scenes)
How web works and browser works ? (behind the scenes)
 
Introduction to GraphQL
Introduction to GraphQLIntroduction to GraphQL
Introduction to GraphQL
 
Introduction to GraphQL at API days
Introduction to GraphQL at API daysIntroduction to GraphQL at API days
Introduction to GraphQL at API days
 
Introduction to GraphQL
Introduction to GraphQLIntroduction to GraphQL
Introduction to GraphQL
 
Building Modern APIs with GraphQL
Building Modern APIs with GraphQLBuilding Modern APIs with GraphQL
Building Modern APIs with GraphQL
 
SharePoint 2013 Javascript Object Model
SharePoint 2013 Javascript Object ModelSharePoint 2013 Javascript Object Model
SharePoint 2013 Javascript Object Model
 
ECS19 - Marco Rocca and Fabio Franzini - Need a custom logic in PowerApps? Us...
ECS19 - Marco Rocca and Fabio Franzini - Need a custom logic in PowerApps? Us...ECS19 - Marco Rocca and Fabio Franzini - Need a custom logic in PowerApps? Us...
ECS19 - Marco Rocca and Fabio Franzini - Need a custom logic in PowerApps? Us...
 
Building a Realtime Chat with React Native (Expo) & GraphQL Subscriptions
Building a Realtime Chat with React Native (Expo) & GraphQL Subscriptions Building a Realtime Chat with React Native (Expo) & GraphQL Subscriptions
Building a Realtime Chat with React Native (Expo) & GraphQL Subscriptions
 
Building SharePoint Single Page Applications Using AngularJS
Building SharePoint Single Page Applications Using AngularJSBuilding SharePoint Single Page Applications Using AngularJS
Building SharePoint Single Page Applications Using AngularJS
 
SharePoint 2010 Client Object Model
SharePoint 2010 Client Object ModelSharePoint 2010 Client Object Model
SharePoint 2010 Client Object Model
 
SharePoint Search Topology and Optimization
SharePoint Search Topology and OptimizationSharePoint Search Topology and Optimization
SharePoint Search Topology and Optimization
 
ECS19 - Mike Ammerlaan - Integrate with OneDrive and SharePoint Files
ECS19 - Mike Ammerlaan - Integrate with OneDrive and SharePoint FilesECS19 - Mike Ammerlaan - Integrate with OneDrive and SharePoint Files
ECS19 - Mike Ammerlaan - Integrate with OneDrive and SharePoint Files
 
Improve Performance in Fast Search for SharePoint - Comperio
Improve Performance in Fast Search for SharePoint - ComperioImprove Performance in Fast Search for SharePoint - Comperio
Improve Performance in Fast Search for SharePoint - Comperio
 
Leveraging React and GraphQL to Create a Performant, Scalable Data Grid
Leveraging React and GraphQL to Create a Performant, Scalable Data GridLeveraging React and GraphQL to Create a Performant, Scalable Data Grid
Leveraging React and GraphQL to Create a Performant, Scalable Data Grid
 
Firebase presentation
Firebase presentationFirebase presentation
Firebase presentation
 
GitHub and Office 365 video Munich
GitHub and Office 365 video MunichGitHub and Office 365 video Munich
GitHub and Office 365 video Munich
 
ECS19 - Laura Kokkarinen - Everything you need to know about SharePoint site ...
ECS19 - Laura Kokkarinen - Everything you need to know about SharePoint site ...ECS19 - Laura Kokkarinen - Everything you need to know about SharePoint site ...
ECS19 - Laura Kokkarinen - Everything you need to know about SharePoint site ...
 
Firebase - A real-time server
Firebase - A real-time serverFirebase - A real-time server
Firebase - A real-time server
 
02 integrate highchart
02 integrate highchart02 integrate highchart
02 integrate highchart
 

Ähnlich wie Kql and the content search web part

Session 2 branding and site development in SharePoint
Session 2   branding and site development in SharePointSession 2   branding and site development in SharePoint
Session 2 branding and site development in SharePoint
Khoa Quach
 
SharePoint Silverlight Sandboxed solutions
SharePoint Silverlight Sandboxed solutionsSharePoint Silverlight Sandboxed solutions
SharePoint Silverlight Sandboxed solutions
Phil Wicklund
 
Custom SharePoint 2010 solutions without server access
Custom SharePoint 2010 solutions without server accessCustom SharePoint 2010 solutions without server access
Custom SharePoint 2010 solutions without server access
Phil Wicklund
 

Ähnlich wie Kql and the content search web part (20)

O365 Saturday - Deepdive SharePoint Client Side Rendering
O365 Saturday - Deepdive SharePoint Client Side RenderingO365 Saturday - Deepdive SharePoint Client Side Rendering
O365 Saturday - Deepdive SharePoint Client Side Rendering
 
The SharePoint & jQuery Guide
The SharePoint & jQuery GuideThe SharePoint & jQuery Guide
The SharePoint & jQuery Guide
 
The SharePoint and jQuery Guide by Mark Rackley - SPTechCon
The SharePoint and jQuery Guide by Mark Rackley - SPTechConThe SharePoint and jQuery Guide by Mark Rackley - SPTechCon
The SharePoint and jQuery Guide by Mark Rackley - SPTechCon
 
Session 2 branding and site development in SharePoint
Session 2   branding and site development in SharePointSession 2   branding and site development in SharePoint
Session 2 branding and site development in SharePoint
 
2012 - HTML5, CSS3 and jQuery with SharePoint 2010
2012 - HTML5, CSS3 and jQuery with SharePoint 20102012 - HTML5, CSS3 and jQuery with SharePoint 2010
2012 - HTML5, CSS3 and jQuery with SharePoint 2010
 
PPT
PPTPPT
PPT
 
Self-serve analytics journey at Celtra: Snowflake, Spark, and Databricks
Self-serve analytics journey at Celtra: Snowflake, Spark, and DatabricksSelf-serve analytics journey at Celtra: Snowflake, Spark, and Databricks
Self-serve analytics journey at Celtra: Snowflake, Spark, and Databricks
 
Google Cloud Dataflow
Google Cloud DataflowGoogle Cloud Dataflow
Google Cloud Dataflow
 
SharePoint Silverlight Sandboxed solutions
SharePoint Silverlight Sandboxed solutionsSharePoint Silverlight Sandboxed solutions
SharePoint Silverlight Sandboxed solutions
 
Integrate MongoDB & SQL data with a single REST API
Integrate MongoDB & SQL data with a single REST APIIntegrate MongoDB & SQL data with a single REST API
Integrate MongoDB & SQL data with a single REST API
 
SharePoint and the User Interface with JavaScript
SharePoint and the User Interface with JavaScriptSharePoint and the User Interface with JavaScript
SharePoint and the User Interface with JavaScript
 
A Beginner's Guide to Client Side Development with Javascript
A Beginner's Guide to Client Side Development with JavascriptA Beginner's Guide to Client Side Development with Javascript
A Beginner's Guide to Client Side Development with Javascript
 
M Pages Technical Forum - Client Server Architectures
M Pages Technical Forum - Client Server ArchitecturesM Pages Technical Forum - Client Server Architectures
M Pages Technical Forum - Client Server Architectures
 
Developing With Data Technologies
Developing With Data TechnologiesDeveloping With Data Technologies
Developing With Data Technologies
 
Mike Taulty MIX10 Silverlight Frameworks and Patterns
Mike Taulty MIX10 Silverlight Frameworks and PatternsMike Taulty MIX10 Silverlight Frameworks and Patterns
Mike Taulty MIX10 Silverlight Frameworks and Patterns
 
Back-end (Flask_AWS)
Back-end (Flask_AWS)Back-end (Flask_AWS)
Back-end (Flask_AWS)
 
2014.06.25 State of the Web Development 2014
2014.06.25 State of the Web Development 20142014.06.25 State of the Web Development 2014
2014.06.25 State of the Web Development 2014
 
MSDN Dec2007
MSDN Dec2007MSDN Dec2007
MSDN Dec2007
 
New-Age Search through Apache Solr
New-Age Search through Apache SolrNew-Age Search through Apache Solr
New-Age Search through Apache Solr
 
Custom SharePoint 2010 solutions without server access
Custom SharePoint 2010 solutions without server accessCustom SharePoint 2010 solutions without server access
Custom SharePoint 2010 solutions without server access
 

Mehr von InnoTech

Mehr von InnoTech (20)

"So you want to raise funding and build a team?"
"So you want to raise funding and build a team?""So you want to raise funding and build a team?"
"So you want to raise funding and build a team?"
 
Artificial Intelligence is Maturing
Artificial Intelligence is MaturingArtificial Intelligence is Maturing
Artificial Intelligence is Maturing
 
What is AI without Data?
What is AI without Data?What is AI without Data?
What is AI without Data?
 
Courageous Leadership - When it Matters Most
Courageous Leadership - When it Matters MostCourageous Leadership - When it Matters Most
Courageous Leadership - When it Matters Most
 
The Gathering Storm
The Gathering StormThe Gathering Storm
The Gathering Storm
 
Sql Server tips from the field
Sql Server tips from the fieldSql Server tips from the field
Sql Server tips from the field
 
Quantum Computing and its security implications
Quantum Computing and its security implicationsQuantum Computing and its security implications
Quantum Computing and its security implications
 
Converged Infrastructure
Converged InfrastructureConverged Infrastructure
Converged Infrastructure
 
Making the most out of collaboration with Office 365
Making the most out of collaboration with Office 365Making the most out of collaboration with Office 365
Making the most out of collaboration with Office 365
 
Blockchain use cases and case studies
Blockchain use cases and case studiesBlockchain use cases and case studies
Blockchain use cases and case studies
 
Blockchain: Exploring the Fundamentals and Promising Potential
Blockchain: Exploring the Fundamentals and Promising Potential Blockchain: Exploring the Fundamentals and Promising Potential
Blockchain: Exploring the Fundamentals and Promising Potential
 
Business leaders are engaging labor differently - Is your IT ready?
Business leaders are engaging labor differently - Is your IT ready?Business leaders are engaging labor differently - Is your IT ready?
Business leaders are engaging labor differently - Is your IT ready?
 
AI 3.0: Is it Finally Time for Artificial Intelligence and Sensor Networks to...
AI 3.0: Is it Finally Time for Artificial Intelligence and Sensor Networks to...AI 3.0: Is it Finally Time for Artificial Intelligence and Sensor Networks to...
AI 3.0: Is it Finally Time for Artificial Intelligence and Sensor Networks to...
 
Using Business Intelligence to Bring Your Data to Life
Using Business Intelligence to Bring Your Data to LifeUsing Business Intelligence to Bring Your Data to Life
Using Business Intelligence to Bring Your Data to Life
 
User requirements is a fallacy
User requirements is a fallacyUser requirements is a fallacy
User requirements is a fallacy
 
What I Wish I Knew Before I Signed that Contract - San Antonio
What I Wish I Knew Before I Signed that Contract - San Antonio What I Wish I Knew Before I Signed that Contract - San Antonio
What I Wish I Knew Before I Signed that Contract - San Antonio
 
Disaster Recovery Plan - Quorum
Disaster Recovery Plan - QuorumDisaster Recovery Plan - Quorum
Disaster Recovery Plan - Quorum
 
Share point saturday access services 2015 final 2
Share point saturday access services 2015 final 2Share point saturday access services 2015 final 2
Share point saturday access services 2015 final 2
 
Sp tech festdallas - office 365 groups - planner session
Sp tech festdallas - office 365 groups - planner sessionSp tech festdallas - office 365 groups - planner session
Sp tech festdallas - office 365 groups - planner session
 
Power apps presentation
Power apps presentationPower apps presentation
Power apps presentation
 

Kürzlich hochgeladen

Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Victor Rentea
 
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Victor Rentea
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Safe Software
 

Kürzlich hochgeladen (20)

Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
Spring Boot vs Quarkus the ultimate battle - DevoxxUK
Spring Boot vs Quarkus the ultimate battle - DevoxxUKSpring Boot vs Quarkus the ultimate battle - DevoxxUK
Spring Boot vs Quarkus the ultimate battle - DevoxxUK
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
DBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor PresentationDBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor Presentation
 
Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : Uncertainty
 
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
 
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
 
DEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 AmsterdamDEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
 
AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of Terraform
 
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
 
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWEREMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
 

Kql and the content search web part

  • 1. KQL AND THE CONTENT SEARCH WEB PART (CSWP) IT Pro Solutions leveraging SharePoint 2013 search abilities (and KQL,REST and jQuery).
  • 2. ABOUT ME: PAUL MCCOLLUM SharePoint Platform Manager at 7-Eleven Inc. MCITP SharePoint 2010, MCTS SQL Server, SP 2007,WSS @SharePointShark (www.sharepointyesNO.net) Programming since 1978 Technology Evangelist/Forecaster www.everythingUSB.com www.ohGizmo.com Solution Architect JavaScript sub-guru Intranet Platform Manager/Governance/Solution Architecture {paul_mccollum}AT{Hotmail}
  • 3. LEANING INTO A NEW ERA  Content Creation Explosion  The ease of SharePoint turned many people and businesses into content publishing machines.  And in many cases the machines turned into monsters.  People didn’t understand Content Governance.  Search is similar.  Due to the technology of the time:  Content loading was slow  Search was SLOWER and resource intensive.  No need for concepts like tagging or SEO.
  • 4. BUT…  We still handle search with tongs like we are worried it's going to break again.  There's usually ONLY:  A search page.  A search box. I’m so lonely.
  • 5. WHY AREN’T WE LEVERAGING SEARCH MORE?  Since search data is cached well, the heavy lifting is done by the crawl.  Search queries can actually be more performant than those from native data.  This gives us a reason to take a second look at content we surface and see if it could be improved with search data.  With FAST Search in SharePoint we can now look at Search as a Primary Data Source
  • 6. CONTENT SEARCH WEB PART  The Content Search Web Part is one of the easiest ways to start “turning the corner” to grab and correlate data to provide more useful information to the user.  With CSWP you can very easily coalesce topic based information and not be as worried about the source or physical location of the data.  Currently working in o365 (November 2013)
  • 7. CSWP, KQL AND DISPLAY TEMPLATES  Now that we see a little bit of the technology change, we can start to look at making use of it to power mini-applications.  Content Search Web Part  Simple and Wizard driven.  KQL  A pseudo-language and syntax to refine search queries beyond the Wizard.  No more CAML  Display Templates  HTML formatting, no XSLT  Can be extended with JavaScript and jQuery.  REST Connectors  Use as a raw data source for apps  No more CAML
  • 8. OUT OF THE BOX, IT LEAVES A LOT TO BE DESIRED.
  • 9. HOWEVER, THE QUERY WIZARD IS PRETTY AWESOME
  • 10. CSWP : EXAMPLES  Demo: Create CSWPs
  • 12. CSWP : VS. WMS  WMS (Work Management Service)  Limited  Fast  Tied to User Profile, Search and WMS Services  CSWP  Flexible  Predictable  Only dependent on Search Service
  • 13. KQL  KQL: The language of Search  2 types  Keyword  Generic word search  Word or Words  "a phrase“  * wildcard: works for words but only for the end of phrases  Property Filter  Targeted and Refined for specific columns or metadata
  • 14. KQL  Property Filtering (syntax)  Author equals “John Smith”  <Property Name> <Property Operator> <Property Value>  author:"John Smith"  secondaryfiletype:docx  filename:budget.xlsx  Property Names must be Managed Fields in SharePoint  Unmanaged fields must be registered to show up in Search (Huge list available by default)  Property Operators  (numeric, int, DateTime) : = < > <= >= <> ..  (string/bool) : =  Other Operators  UNION AND (+) OR NOT (-) NEAR ONEAR
  • 15. KQL  Variables (from requestor context)  {Site.URL}  {Site.<property>}  {Page.URL}  {URLToken.<integer>}  {User.Name}  {User.Email}  {User.<property>}  Many more…. https://technet.microsoft.com/en- us/library/jj683123.aspx
  • 16. KQL  Attributes (from result set)  https://technet.microsoft.com/en-us/library/jj219630.aspx
  • 17. KQL  Demo of KQL and config of CSWP  THEN *Audience Participation*
  • 18. EXAMPLES  Is my stuff getting old?  Author={User.Name} LastModifiedTime<{Today-65}  What have I been working on this week?  Author={User.Name} LastModifiedTime>{Today-5}  My ears are burning. Who’s talking about me?  Author<>{User.Name} AND ( {User.LastName} OR {User.Email} )  Who’s messing with my Stuff?  Author={User.Name} ModifiedBy<>{User.Name}  Manage My Content  These files are too big.  Size>30000000  These files should only be on certain sites.  (SecondaryFileExtension=wmv OR SecondaryFileExtension=avi OR SecondaryFileExtension=mpg OR SecondaryFileExtension=asf OR SecondaryFileExtension=mp4 OR SecondaryFileExtension=ogg OR SecondaryFileExtension=ogv OR SecondaryFileExtension=webm)  These words really shouldn’t be on the site.  “Damn” “heck” “chick” “credit card” “SSN”  What’s new in HR this week?  path:"http://SITE/HR/" (IsDocument:"True" OR Contentclass:"STS_ListItem") LastModifiedTime>{Today-5}  Governance
  • 19. EXAMPLES: BONUS ROUND  (  SecondaryFileExtension=jpg  OR SecondaryFileExtension=gif  OR SecondaryFileExtension=bmp  OR SecondaryFileExtension=png  OR SecondaryFileExtension=tiff  OR SecondaryFileExtension=raw  )  “Mud” “soil” “earth”
  • 20. USEFUL ALONE OR IN GROUPS
  • 21. DISPLAY TEMPLATES : MECHANICS Display Templates are very similar to the CQWP XSLT templates. An Outer Template calls a looping Inner Template. No longer XML and XSLT HTML and JavaScript with ‘Server Side’ Substitution
  • 22. DISPLAY TEMPLATES : MECHANICS To Access Display Template • Map Network Drive • Don’t need Designer
  • 23. DISPLAY TEMPLATES : CODE Result Variable Column Mapping
  • 24. DISPLAY TEMPLATES : CODE Variable Assignment Display HTML
  • 25. DISPLAY TEMPLATES : EXAMPLES Demo of Display Template alterations
  • 26. THE REST: WITH REST AND JQUERY HTML vs .Net Document Library Versioning No Compilation Content Editor Web Part Script Web Part Cloud Friendly
  • 27. THE REST: WITH REST AND JQUERY REST, HTML and jQuery More Power More Flexibility Fewer Hoops
  • 28. THE REST: WITH REST AND JQUERY  Learning REST  POST or GET  Chrome’s Dev HTTP Client  Fiddler
  • 29. THE REST: WITH REST AND JQUERY jQuery Ajax JSON .each()
  • 30. THE REST: WITH REST AND JQUERY Places to get ideas DynamicDrive.com JavascriptKit.com Smashingapps.com
  • 31. THE REST: WITH REST AND JQUERY Steps Create query URL (REST) Load into Array Convert to HTML structure (if needed) Wire-up to flashy plugin
  • 32. JQUERY APPS : EXAMPLES  Demo: Create REST Search mini App
  • 33. RESOURCES  KQL  http://msdn.microsoft.com/en-us/library/sharepoint/ee558911.aspx  http://msdn.microsoft.com/en-us/library/jj163973.aspx  Search Variables  http://technet.microsoft.com/en-us/library/jj683123.aspx  Default Crawled Properties  http://technet.microsoft.com/en-us/library/jj219630.aspx  Display Template Reference  http://technet.microsoft.com/en-us/library/jj944947.aspx  http://msdn.microsoft.com/en-us/library/jj945138.aspx  Codeplex sharepoint query tool.  REST Endpoints  http://msdn.microsoft.com/en-us/library/office/apps/jj860569.aspx  REST Programming  http://www.plusconsulting.com/blog/2013/05/crud-on-list-items-using-rest-services-jquery/  SharePoint Search REST API overview (http://server/_api/search/query?querytext='sharepoint')  http://msdn.microsoft.com/EN-US/library/sharepoint/jj163876.aspx  Working with Result data from REST calls  http://sharepointfieldnotes.blogspot.com/2013/01/sharepoint-2013-search-with-rest-app.html  Image Rotator  http://www.dynamicdrive.com/dynamicindex14/shockwave/index.htm