Creating a report for incidents count is more than 3 and having same CI

Gaurav Vaze
Kilo Sage

Hello guys,

I have a requirement for the report, which should provide the user with incidents for a given list of CI

but the catch here is the report should only show those incidents, for which the count of incidents related to that CI is greater than 3.

i.e. if there is CI named x and the incidents including this CI are more than 3; and there is Ci named y and incidents including CI y are less than 3 then the report should show the incidents for x

 

Any help will be appreciated 

Gaurav Vaze
ServiceNow developer

8 REPLIES 8

Hi @Gaurav Vaze - Have you seen my response above providing the solution? No Script Include etc required... or have I missed the brief?

 

To help others (or for me to help you more directly), please mark this response correct by clicking on Accept as Solution and/or Kudos.



Thanks, Robbie

Robbie
Kilo Patron
Kilo Patron

Hi @Gaurav Vaze,

 

Unless I'm missing something, this is easily achieved by leveraging the 'Related List Condition' section of a report.

See the below screen shot.

This is simply a List report based on the cmdb_ci table. Then, within the 'Related List Condition' I've simply configured that the list must be Greater or Equal to 2 (For my instance), you can set this to 3.

 

This show all CI's where 2 (or 3 in your case) incident's have been raised against those CI's - simple.

 

Am I missing something here?

 

To help others (or for me to help you more directly), please mark this response correct by clicking on Accept as Solution and/or Kudos.



Thanks, Robbie

 

Screenshot 2024-08-29 at 11.41.34.png

I see the solution
but wont this will return the CI instead of INC?

Wow.. awesome my friend @Robbie  Really cool and i tried this. Now issue needs same CI and show the incident details as well. 

 

Do we need build the DB view ?

*************************************************************************************************************
If my response proves useful, please indicate its helpfulness by selecting " Accept as Solution" and " Helpful." This action benefits both the community and me.

Regards
Dr. Atul G. - Learn N Grow Together
ServiceNow Techno - Functional Trainer
LinkedIn: https://www.linkedin.com/in/dratulgrover
YouTube: https://www.youtube.com/@LearnNGrowTogetherwithAtulG
Topmate: https://topmate.io/atul_grover_lng [ Connect for 1-1 Session]

****************************************************************************************************************