Monday, January 24, 2011

SharePoint 2010 - Content Query Web Part (CQWP) Slow Loading New Items?

We've recently implemented several Content Query Web Parts (CQWP) which I love. However, I noticed that new items weren't showing up so quickly. I did a couple of quick checks to make sure items weren't checked out or unapproved but to no avail.

Then, after some digging, I came across the following article from Michael Nemtsev: Why Content Query Web Part (CQWP) doesn’t return all results.

The workaround is a simple one:
set “UseCache” property to “false”.

Interesting note from the SharePoint Team:

Cite from SharePoint Team:

“You are only seeing your items in edit mode because the caching infrastructure of the CQWP does not cache checked-out items of individual users and we disable cache in edit mode. You can disable caching on your Web Part by setting the "UseCache" property to false”

Just a handy note in case anyone else has trouble with that very useful (but sometimes pesky) Content Query Web Part.