Object Reference for the Salesforce Platform
Note: This release is in preview. Features described here don’t become generally available until the latest general availability date that Salesforce announces for this release. Before then, and where features are noted as beta, pilot, or developer preview, we can’t guarantee general availability within any particular time frame or at all. Make your purchase decisions only on the basis of generally available products and features.
KnowledgeArticleViewStat
Knowledge__ViewStat is derived from this object.
Supported Calls
describeSObjects(), query(), retrieve()
Special Access Rules
Knowledge must be enabled in your org. Users must have access to the published and archived versions of an article to retrieve its views. For more information on published and archived article versions, see the PublishStatus field in KnowledgeArticleVersion.
Fields
Usage
Use this object to query or retrieve certain statistics for article views.
Alternatively, client applications can use the article type API Name followed by __ViewStat to query or retrieve most viewed articles from a specific article type.
SOQL Samples
The following SOQL clause uses KnowledgeArticleViewStat to query all the article views in Salesforce Knowledge and return the related articles:
1SELECT Id, NormalizedScore, Parent.Id
2 FROM KnowledgeArticleViewStat where Channel = 'App'
3 ORDER BY NormalizedScoreUse the following clause to restrict your query to Offer articles for the Offer article type:
1SELECT Id, NormalizedScore, Parent.Id
2 FROM Offer__ViewStat where Channel = 'App'
3 ORDER BY NormalizedScore