1

Essentially, I have a Popular items webpart on a page, analytics is running - usage reports are being generated but results are not displaying correctly in the webpart. The popular items is set to a page library.

If I were to look at the usage reports or view the popular items page - I can retrieve these results. However the webpart seems to be listing the results in alphabetical order. There is no sort specified on the webpart. Interestingly enough, using the '_api/search/query' with 'viewsrecent' seems to be returning null values.

My troubleshooting thus far... Checked search services, crawl status, tail trim, recent popularity timeframe and running services on server...

Any ideas where else to look?

0

The Popular Items web part sorts search results in a descending order on the ViewsRecent managed property. By default, the ViewsRecent managed property contains the number of views for an item within the last 14 days.

Check the blog for more information about Popular Items Web Part.

You can use the Content Search web part and sorted by ViewsLifeTime managed property. The result of the count is generated from the indexed value of the ViewsLifeTime. When the page is viewed, it will add the count to this ViewsLifeTime field. The SharePoint crawler will pick up the change.

Note: Ensure “Hide physical URLS from search” is unchecked. If the “Hide physical URLS from search” is “Yes”, the page will not be indexed and the ViewsLifeTime field will not hold the count of view in the field.

  • Thanks for the speedy reply - I've had a look at the search results behind the popular items web part and I'm getting nulls. I used '_api/search/query?querytext=' - this didn't return any usable stats, only nulls. However going to the 'Popular Items' page for my Page Library shows the recent views as expected. Any idea what could be causing that? I can confirm 'hide physical urls' is unchecked. – Matthew Brown Dec 19 '17 at 16:23

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.