Loading

Count the Number of Times an Article was Viewed by Internal Users

게시 일자: Sep 21, 2024
상세 설명

Admins might want to know certain statistics about articles on how many views it got internally or externally so that they can decide to archive or keep certain articles.

솔루션

There is an object in Salesforce called the KnowledgeArticleViewStat which can be used for accessing certain statistics related to the article views, like the NormalizedScore and the ViewCount.

Viewcount gives the number of unique views a published or archived article has received in the selected channel. 

A Channel is where the article is viewed:

  • AllChannels for article views across all channels.
  • App for the internal Salesforce Knowledge application.
  • Pkb for article views in public knowledge base.
  • Csp for Customer Portal.
  • Prm for article view in partner portal.


In the Developer Console, the following SOQL query example will return the count for the number of article views by internal users. We can use the Channel App since it is meant for the internal Salesforce Knowledge application. The SOQL query is as follows:

SELECT id, ViewCount from KnowledgeArticleViewStat where Channel = 'App'


 

Knowledge 기사 번호

000383653

 
로드 중
Salesforce Help | Article