Consequences of and/or reasons for changing KB Property glide.knowman.view_age.days from 30 default to 0

Michael QCKM
Tera Guru

Re: Number of days (integer, default 30) used when summing article views (glide.knowman.view_age.days)

I know I've asked this before, but it keeps coming up and it is NOT clear to me or anyone in my group.

We need to understand the consequences of this field when creating Reports and looking at List Views.

  • If I run a Report to see the number of KB articles, never Viewed, Last updated over 1 year ago, I get a big list, but I'm told that it is wrong because it is ONLY really showing the last 30 days.
  • We try to show historical upkeep, like Drafts in queue for over 6 months, or articles in Review for over 6 months, etc.  But everytime I give a report - that looks good - nobody trusts it because they think it's actually only calculating 30 days despite what it seems.

  • If we set this to 0 to show ALL days, is there a negative impact of this?
    • Is anyone doing it this way?
  • If I leave it at 30 days, can I provide accurate historical/trend reports for periods LONGER than 30 days?
Number of days (integer, default 30) used when summing article views (glide.knowman.view_age.days) Enter a number of days to consider when calculating view count. The View count field in the Knowledge form will be updated periodically to reflect the view count based on this property. For example, if you enter 60, the view count is the total number of views in the past 60 days. Enter 0 to have ServiceNow consider all views, regardless of date.
Note: If you edit this property, run the Count Knowledge Use scheduled job to see the changes immediately. By default, the Count Knowledge Use scheduled job runs daily and updates the view counts on the knowledge articles. To view the scheduled job, navigate to System Scheduler > Scheduled Jobs > Scheduled Jobs.

New customers as of the Paris release will not have access to the View count property and Count Knowledge scheduled job. Existing customers prior to the Paris release can continue to use the property and scheduled job.

If you set the property value to 0:

  • The Count Knowledge scheduled job does not run.
  • The View count of an article contains the accumulated value of total count.
2 ACCEPTED SOLUTIONS

Ah, yes, you can see the ones that weren't viewed in the last 30 days looking at the records with "sys_view_count = 0", but those might have been viewed before that.

It's hard to report on things that didn't happen, in your case, the easiest way to find articles that have never been used is to make list of KB numbers from your kb_knowledge table, another list of unique numbers in kb_use, and diff both lists. Very manual, but I don't see any other quick solution.

I hope this helps.

Kind regards,
Lucas Vieites
P.S. If my reply helped you, please mark it as helpful or correct so other community members can benefit from this information.

View solution in original post

Tommy SN Sahlin
Kilo Sage

Hi @Michael QCKM , @Lucas Vieites and @Chris Armstron1 

 

I just stumbled over this post which has been quiet for over a year, but if I understand correctly what you are trying to achieve report-wise, I think you can do it quite easily in Report Designer.

 

  1. Create a new report based on the kb_knowledge table, set other conditions as needed
  2. Click Related List Conditions at the bottom of the Conditions section
  3. Click on the phrase "Greater than or Equal to 1", change it to "None"
  4. Click the -Table- dropdown, select "Knowledge Use->Article", set other conditions as need

Once done it should look like this:

TommySNSahlin_0-1677072552120.png


You have now told the report to return a list of all articles in the kb_knowledge table that do NOT exist in the kb_use table = have not been viewed.

 

cheers, hope that helps /Tommy

View solution in original post

13 REPLIES 13

Lucas Vieites
Tera Guru

  Hi Michael,

  This is a complex topic that appears on the forums every once in a while, and there is some confusion around the default functionality of the KB article view counts. I have to review my notes every time I get a question because it’s confusing, but these are the highlights:

  • The View count field on the KB article table increases every time someone loads the article for viewing (whether it's from the legacy kb_view.do or the KB portal). This field is affected by the property glide.knowman.view_age.days and is updated when the Count Knowledge Use job runs. By default, this will show you the number of views in the last 30 days (the data is taken from the kb_use table).
    • If you set the property to 0, it will not be updated, so you will keep adding all the views from that moment onwards.
  • The kb_use table contains the historical view data (as well as use data, when an article is attached to a task, for example). This table does not get cleaned, by default, so this is where you would get “all-time views”.

  As an example, see this data from a test instance:

  If you look at the top 5 articles, you will see that KB0010013 has been viewed 58 times since it was created, but 0 times in the last 30 days. KB0010028 has been viewed 35 times since creation, and 35 times in the last 30 days (I’ve been reloading it as part of some tests I was doing).

Article number

Knowledge Use Count

(kb_use)

View count

(kb table)

KB0010013

58

0

KB0010021

43

0

KB0010008

40

0

KB0010028

35

35

KB0010004

30

0

KB0010026

25

2

KB0010027

13

3

KB0010003

9

0

KB0010006

8

0

KB0010056

7

0

KB0000011

5

0

KB0010002

5

0

KB0010054

5

0

KB0000008

4

0

KB0010001

4

0

KB0011105

3

0

KB0000005

2

0

KB0000028

2

0

KB0010014

2

0

KB0010024

2

0

KB0000006

1

0

KB0000009

1

0

KB0000012

1

0

KB0000024

1

0

KB0000032

1

0

KB0010012

1

0

  The only impact you will see if you set the property to zero is the increase in time the Count Knowledge Use job will run in the future, but this should not be noticeable.

I hope this helps you.

Kind regards,
Lucas Vieites
P.S. If my reply helped you, please mark it as helpful or correct so other community members can benefit from this information.

Thank you Lucas. Your description does help. I will need to revisit the WHY I asked this question, what I was trying to achieve, etc. 

I just tried to run a List View query using the kb_use table, and the same in the kb_knowledge table, and got different results... I'll need to review the WHY, and also try to create similar in Reports to see if different.

Thank you for your insight; I surely welcome any other feedback to this if anyone else is also experiencing headscratching confusion or issues.

@Lucas Vieites  Hi.....

I do have same requirement. Is there any way to fetch total view count for all versions?

 

TIA

Hi @Lucas Vieites  and @Michael QCKM 

Can you please help me in understanding how the 'Use count' field in knowledge table and the 'Used' field in kb_use table gets populated or incremented?

I thought both fields provides the same data like as how many times the knowledge article has been attached to any record but I am noticing that there is a discrepancy or difference between these data for these two fields in knowledge and kb_use table.

It will be very helpful if you guide me in understanding why the data for 'Use count' field in knowledge table is not similar and is more that the data present in the 'Used' field in kb_use table? 

Like: If the ' use count' field for any knowledge article (for a particular version) is showing as 10 in knowledge table, the 'used' field is showing as 2 for that particular article.