SlideShare a Scribd company logo
Deep Dive into the
Content Query Web Part
Christina Wheeler
Agenda
• Introduction
• Content Query Web Part
  – About the CQWP
  – How it’s being used
  – Tips & tricks
  – How to Customize
Deep Dive into the Content Query Web Part by Christina Wheeler - SPTechCon
About me…
• Christina Wheeler
• SharePoint Trainer & Consultant

•   B: http://www.thesharepoint411.com
•   E: cwheeler76@live.com
•   L: http://www.linkedin.com/in/christinawheeler
•   T: @cwheeler76
Publications
SharePoint 2010 Field Guide
http://bit.ly/Xoxatd



SharePoint 2013 Inside Out
http://oreil.ly/Wtk2UV
CQWP
• Used to aggregate content from SharePoint
  lists & libraries from within the current site
  collection
• Filter by content types
• Add additional columns
• Presentation styling
• Audience Targeting
What’s new?
• Dynamic Filters
  – SharePoint 2007
     • You had to subclass the CQWP to add dynamic filters
  – SharePoint 2010
     • Filters based off other fields on the page
     • Or from a value on the QueryString
What’s new?
• CommonViewFields
  – SharePoint 2007
     • Had to export web part.
     • Tweak the CommonViewFields property.
     • Reimport to page to pass additional content
       fields down to the XSLT for rendering.
  – SharePoint 2010
     • Now exposed in the CQWP’s Editor part
Controlling the Presentation
• Use existing Styles from the style gallery
• Levels are set using the presentation section
  in the tool pane
• Create Custom XSL
  – Conditional Formatting
  – Key Performance Indicators
  – Calendar displays
Building the Query
Building the Query
• PageFieldValue
  – Token allows to specify field on page layout and
    dynamically replaces value of filter with current page’s
    field value
• PageQueryString
  – Use URL query string for a value to use in Query
  – Example
     • Add Query String value to URL (&NewsCategory=Sports”)
       and set the CQWP’s query to return pages where the News
       Category field is equal to “Sports”
Building the Query
Building the Query
• Supports filtering over the Enterprise
  Keywords columns and the “All Tags” column
  – Allows to look for any
    managed metadata
    tag on a queried item,
    regardless of
    which metadata field
    on the item contains
    the tag.
Building the Query
Building the Query
Resources
• SharePoint 2010 CAML Designer
  – http://karinebosch.wordpress.com/2012/05/12/caml-
    designer/
• Stramit CAML Viewer
  – http://spcamlviewer.codeplex.com
• Lightning Conductor Web Part
  – http://www.lightningtools.com
QUESTIONS?
Contact Info
• Email
 cwheeler76@live.com
• Blog
 http://www.thesharepoint411.com
• Twitter
 @cwheeler76
• LinkedIn
 http://www.linkedin.com/in/christinawheeler

More Related Content

PDF
Tutorial, Part 2: SharePoint 101: Jump-Starting the Developer by Rob Windsor ...
PDF
ECS19 - Laura Kokkarinen - Everything you need to know about SharePoint site ...
PPTX
Content query web part – get it all in one place and style it!
PPTX
Using js link and display templates
PDF
SPSSTHLM - Using JSLink and Display Templates for ITPros
PPT
Automating SQL Server Database Creation for SharePoint
PPTX
[Jansen] Transforming your classic team sites into modern group connected tea...
PPTX
SharePoint Development (Lesson 3)
Tutorial, Part 2: SharePoint 101: Jump-Starting the Developer by Rob Windsor ...
ECS19 - Laura Kokkarinen - Everything you need to know about SharePoint site ...
Content query web part – get it all in one place and style it!
Using js link and display templates
SPSSTHLM - Using JSLink and Display Templates for ITPros
Automating SQL Server Database Creation for SharePoint
[Jansen] Transforming your classic team sites into modern group connected tea...
SharePoint Development (Lesson 3)

What's hot (20)

PPTX
ECS 19 Bert Jansen - Taking your SharePoint to the next level – Transforming ...
ODP
Synapse india reviews on share point development
PPTX
SharePoint 2013 APIs
PPTX
SharePoint Framework, React and Office UI SPS Paris 2016 - d01
PPTX
Custom Development for SharePoint
PPT
Tridion Content Broker - how and why we are using it at the RSPB (2007)
PDF
ECS19 - Katja Jokisalo - Modernize your Intranet
PPTX
Gabriel Gayhart - XML Pointer File Example
PPTX
Working with a super model for SharePoint Tuga IT 2016
PPTX
Building No-Code Collaboration Solutions on Office 365
PDF
Pretty Up My SharePoint
PPTX
Share point developement Introduction for students
PPTX
Building SharePoint Single Page Applications Using AngularJS
PPTX
SharePoint 2016 Adoption - Lessons Learned and Advanced Troubleshooting
PPTX
I3 - Running SharePoint 2016 in Azure the do's and dont's - Jasjit Chopra
PDF
Application express
PPTX
SharePoint 2016 Platform Adoption Lessons Learned and Advanced Troubleshooting
PPTX
European SharePoint Conference Training Week - Installing SharePoint 2013
PPTX
Building SharePoint add-ins with JavaScript and c# sps Silicon Valley
ECS 19 Bert Jansen - Taking your SharePoint to the next level – Transforming ...
Synapse india reviews on share point development
SharePoint 2013 APIs
SharePoint Framework, React and Office UI SPS Paris 2016 - d01
Custom Development for SharePoint
Tridion Content Broker - how and why we are using it at the RSPB (2007)
ECS19 - Katja Jokisalo - Modernize your Intranet
Gabriel Gayhart - XML Pointer File Example
Working with a super model for SharePoint Tuga IT 2016
Building No-Code Collaboration Solutions on Office 365
Pretty Up My SharePoint
Share point developement Introduction for students
Building SharePoint Single Page Applications Using AngularJS
SharePoint 2016 Adoption - Lessons Learned and Advanced Troubleshooting
I3 - Running SharePoint 2016 in Azure the do's and dont's - Jasjit Chopra
Application express
SharePoint 2016 Platform Adoption Lessons Learned and Advanced Troubleshooting
European SharePoint Conference Training Week - Installing SharePoint 2013
Building SharePoint add-ins with JavaScript and c# sps Silicon Valley
Ad

Viewers also liked (20)

PPTX
PDF
Creating Simple Dashboards Using Out-of-the-Box Web Parts by Jennifer Mason- ...
PPTX
Office 365 Groups - What's in it for me
PPTX
Power Users Guide to Office 365 - SharePoint Saturday Belgium 2016 #spsbe
PPTX
SPS New York City 2017 - The Lay of the Land of Client-Side Development circa...
PPTX
SharePoint Client Object Model (CSOM)
PPTX
Biwug 25092012 sp2013_itpro_hans_jaspers
PPTX
CSOM (Client Side Object Model). Explained @ SharePoint Saturday Houston
PPTX
The SharePoint & jQuery Guide
PPTX
Karine bosch andy-van_steenbergen-caml-spsbe12
PPTX
Data Access Options in SharePoint 2010
PPTX
LINQ to SharePoint
PPTX
Social features in SharePoint 2013
PPTX
SharePoint and Office Development Workshop
PDF
[BA09] 生産性/利便性を追求した最先端の業務アプリケーションとは!? ~Dynamics 365/Office 365 とチャットアプリケーションと...
PPTX
SharePoint communications sites overview presentation
PPTX
"Reinventing Content Collaboration - the Future of SharePoint is Now!" | SPTe...
PPTX
SharePoint hub sites overview
PDF
[BA03] チームの働き方を劇的に変える!~ Microsoft Teams の概要と開発プラットフォーム
PDF
[BA01] もうすぐ満 6 歳! Office 365 の最新機能で到達する働き方改革の姿
Creating Simple Dashboards Using Out-of-the-Box Web Parts by Jennifer Mason- ...
Office 365 Groups - What's in it for me
Power Users Guide to Office 365 - SharePoint Saturday Belgium 2016 #spsbe
SPS New York City 2017 - The Lay of the Land of Client-Side Development circa...
SharePoint Client Object Model (CSOM)
Biwug 25092012 sp2013_itpro_hans_jaspers
CSOM (Client Side Object Model). Explained @ SharePoint Saturday Houston
The SharePoint & jQuery Guide
Karine bosch andy-van_steenbergen-caml-spsbe12
Data Access Options in SharePoint 2010
LINQ to SharePoint
Social features in SharePoint 2013
SharePoint and Office Development Workshop
[BA09] 生産性/利便性を追求した最先端の業務アプリケーションとは!? ~Dynamics 365/Office 365 とチャットアプリケーションと...
SharePoint communications sites overview presentation
"Reinventing Content Collaboration - the Future of SharePoint is Now!" | SPTe...
SharePoint hub sites overview
[BA03] チームの働き方を劇的に変える!~ Microsoft Teams の概要と開発プラットフォーム
[BA01] もうすぐ満 6 歳! Office 365 の最新機能で到達する働き方改革の姿
Ad

Similar to Deep Dive into the Content Query Web Part by Christina Wheeler - SPTechCon (20)

PDF
The Humble & Mighty SharePoint URL Query String
PPTX
Kql and the content search web part
PPT
Iw411 migrating content by search from 2010 into 2013 - minified
PPTX
SharePoint 2010 Content Query Web Part
PPTX
Content Web Parts Presentation from SPFest Chicago
PPTX
Customizing the SharePoint 2013 user interface with JavaScript - Chris OBrien
PPTX
Content by query web part
PPTX
SPCA2013 - Content Search Web Part
PPTX
Spsvb Developer Intro to SharePoint Search
PPTX
Spsvb Developer Intro to SharePoint Search
PDF
SharePoint User Group Meeting- SharePoint 2013 Search
PPTX
Introduction to Content Search Web Part
PPTX
Search Queries Explained – A Deep Dive into Query Rules, Query Variables and ...
PPTX
Fives ways to query SharePoint 2013 Search - SharePoint Summit Toronto 2013
PPTX
SharePoint 2013 Search - A Developer’s Perspective - SPSSV 2013
PPTX
#SPSPhilly search topology & optimization
PPTX
TechFuse 2013 - Break down the walls SharePoint 2013
PPTX
#SPSLondon - Session 1 - Building an faq for end users
PDF
Build killer visuals to interact with your content using Search and Display T...
PPTX
Creating an FAQ for end users, An evolution of an idea - SharePoint Saturday ...
The Humble & Mighty SharePoint URL Query String
Kql and the content search web part
Iw411 migrating content by search from 2010 into 2013 - minified
SharePoint 2010 Content Query Web Part
Content Web Parts Presentation from SPFest Chicago
Customizing the SharePoint 2013 user interface with JavaScript - Chris OBrien
Content by query web part
SPCA2013 - Content Search Web Part
Spsvb Developer Intro to SharePoint Search
Spsvb Developer Intro to SharePoint Search
SharePoint User Group Meeting- SharePoint 2013 Search
Introduction to Content Search Web Part
Search Queries Explained – A Deep Dive into Query Rules, Query Variables and ...
Fives ways to query SharePoint 2013 Search - SharePoint Summit Toronto 2013
SharePoint 2013 Search - A Developer’s Perspective - SPSSV 2013
#SPSPhilly search topology & optimization
TechFuse 2013 - Break down the walls SharePoint 2013
#SPSLondon - Session 1 - Building an faq for end users
Build killer visuals to interact with your content using Search and Display T...
Creating an FAQ for end users, An evolution of an idea - SharePoint Saturday ...

More from SPTechCon (20)

PDF
NOW I Get It... What SharePoint Is, and Why My Business Needs It by Mark Rack...
PPTX
“Managing Up” in Difficult Situations by Bill English - SPTechCon
PPTX
Part I: SharePoint 2013 Administration by Todd Klindt and Shane Young - SPTec...
PPTX
Part II: SharePoint 2013 Administration by Todd Klindt and Shane Young - SPTe...
PPTX
Microsoft Keynote by Richard Riley - SPTechCon
PPTX
Ten Best SharePoint Features You’ve Never Used by Christian Buckley - SPTechCon
PPTX
Looking Under the Hood: How Your Metadata Strategy Impacts Everything You Do ...
PPTX
Law & Order: Content Governance Strategies by Chrisitan Buckley - SPTechCon
PPTX
What IS SharePoint Development? by Mark Rackley - SPTechCon
PPTX
The SharePoint and jQuery Guide by Mark Rackley - SPTechCon
PPTX
Understanding and Implementing Governance for SharePoint 2010 by Bill English...
PPTX
Integrate External Data with the Business Connectivity Services by Tom Resing...
PDF
Converting an E-mail Culture into a SharePoint Culture by Robert Bogue - SPTe...
PPTX
Tutorial: Best Practices for Building a Records-Management Deployment in Shar...
PDF
Tutorial: Building Business Solutions: InfoPath & Workflows by Jennifer Mason...
PDF
Sponsored Session: Better Document Management Using SharePoint by Roland Simo...
PDF
Sponsored Session: The Missing Link: Content-Aware Integration to SharePoint ...
PPTX
Creating a Great User Experience in SharePoint by Marc Anderson - SPTechCon
PPTX
Sponsored Session: Driving the business case and user adoption for SharePoint...
PPTX
Tutorial: SharePoint 2013 Admin in the Hybrid World by Jason Himmelstein - SP...
NOW I Get It... What SharePoint Is, and Why My Business Needs It by Mark Rack...
“Managing Up” in Difficult Situations by Bill English - SPTechCon
Part I: SharePoint 2013 Administration by Todd Klindt and Shane Young - SPTec...
Part II: SharePoint 2013 Administration by Todd Klindt and Shane Young - SPTe...
Microsoft Keynote by Richard Riley - SPTechCon
Ten Best SharePoint Features You’ve Never Used by Christian Buckley - SPTechCon
Looking Under the Hood: How Your Metadata Strategy Impacts Everything You Do ...
Law & Order: Content Governance Strategies by Chrisitan Buckley - SPTechCon
What IS SharePoint Development? by Mark Rackley - SPTechCon
The SharePoint and jQuery Guide by Mark Rackley - SPTechCon
Understanding and Implementing Governance for SharePoint 2010 by Bill English...
Integrate External Data with the Business Connectivity Services by Tom Resing...
Converting an E-mail Culture into a SharePoint Culture by Robert Bogue - SPTe...
Tutorial: Best Practices for Building a Records-Management Deployment in Shar...
Tutorial: Building Business Solutions: InfoPath & Workflows by Jennifer Mason...
Sponsored Session: Better Document Management Using SharePoint by Roland Simo...
Sponsored Session: The Missing Link: Content-Aware Integration to SharePoint ...
Creating a Great User Experience in SharePoint by Marc Anderson - SPTechCon
Sponsored Session: Driving the business case and user adoption for SharePoint...
Tutorial: SharePoint 2013 Admin in the Hybrid World by Jason Himmelstein - SP...

Deep Dive into the Content Query Web Part by Christina Wheeler - SPTechCon

  • 1. Deep Dive into the Content Query Web Part Christina Wheeler
  • 2. Agenda • Introduction • Content Query Web Part – About the CQWP – How it’s being used – Tips & tricks – How to Customize
  • 4. About me… • Christina Wheeler • SharePoint Trainer & Consultant • B: http://www.thesharepoint411.com • E: cwheeler76@live.com • L: http://www.linkedin.com/in/christinawheeler • T: @cwheeler76
  • 5. Publications SharePoint 2010 Field Guide http://bit.ly/Xoxatd SharePoint 2013 Inside Out http://oreil.ly/Wtk2UV
  • 6. CQWP • Used to aggregate content from SharePoint lists & libraries from within the current site collection • Filter by content types • Add additional columns • Presentation styling • Audience Targeting
  • 7. What’s new? • Dynamic Filters – SharePoint 2007 • You had to subclass the CQWP to add dynamic filters – SharePoint 2010 • Filters based off other fields on the page • Or from a value on the QueryString
  • 8. What’s new? • CommonViewFields – SharePoint 2007 • Had to export web part. • Tweak the CommonViewFields property. • Reimport to page to pass additional content fields down to the XSLT for rendering. – SharePoint 2010 • Now exposed in the CQWP’s Editor part
  • 9. Controlling the Presentation • Use existing Styles from the style gallery • Levels are set using the presentation section in the tool pane • Create Custom XSL – Conditional Formatting – Key Performance Indicators – Calendar displays
  • 11. Building the Query • PageFieldValue – Token allows to specify field on page layout and dynamically replaces value of filter with current page’s field value • PageQueryString – Use URL query string for a value to use in Query – Example • Add Query String value to URL (&NewsCategory=Sports”) and set the CQWP’s query to return pages where the News Category field is equal to “Sports”
  • 13. Building the Query • Supports filtering over the Enterprise Keywords columns and the “All Tags” column – Allows to look for any managed metadata tag on a queried item, regardless of which metadata field on the item contains the tag.
  • 16. Resources • SharePoint 2010 CAML Designer – http://karinebosch.wordpress.com/2012/05/12/caml- designer/ • Stramit CAML Viewer – http://spcamlviewer.codeplex.com • Lightning Conductor Web Part – http://www.lightningtools.com
  • 18. Contact Info • Email cwheeler76@live.com • Blog http://www.thesharepoint411.com • Twitter @cwheeler76 • LinkedIn http://www.linkedin.com/in/christinawheeler