logo

NJP

Unlock Powerful Metrics for Non-Task Tables with ServiceNow | ServiceNow Metrics to the Next Level

Import · Feb 04, 2023 · video

[Music] thank you hi all and welcome back so in today's tutorial we'll be exploring one more thing out okay that is with respect to metric okay so if you are not aware okay you must be aware about metric instance because I've worked on a lot of use case where I used my tricks okay but if you are not aware of our metric in servicenow so in service of Matrix are the measures or specific aspect other measure or specific aspect of system performance usage or business process that can be used to track and analyze data over the time okay battery can be used to identify Trend monitor kpis okay and help Drive process Improvement so for example okay uh if you want to see what is the response type of incident okay or how much time a change took to get close to the closest state in all this aspect you can use the metric definitions okay so if you are aware about the same okay a metric instance is applicable or the this calculation is applicable only for the task extended tables okay so how we can how we can extend it out if you want to use the same for non-task table non-task extend table right so in today's tutorial we'll be seeing on the same so the use case for today is lucky for the use case scenarios like this approach table I want to track the state change on the sales approval table so it's approval of row table okay and today we will be seeing how we can do that okay so let's first go and create a metric instance first of all we will see right whether it's getting really it's not getting supported or I'm just creating hype out of it okay so let's go how to go to the metric first of all we have to define the metric definition so for that we have to go to Matrix and the Matrix we have metric definition we want to do it on CS approval approval table right so we'll create a new and we'll give it on true so you can create a definition okay but the calculation will not happen I will show you how so I will give it a name as a proof approve on which particular field out of it so we want to have it on State field how much time it took to move from requested to upgrade or reject kind of things right I will keep it a field duration only and just save it out okay sounds like apply now let's go to the table so for that I will just go to this approve approval underscore approved dot list I always get confused with this name okay so how I make it there are two segments approval and approval okay what comes alphabetically first it will be first so approval L is first and then r you can Define your own logic circuit and now if I open any record for example this requested one if I go over here and if I change this out from requested to approve and I will save it out okay and from approved I move it will not take that it will not take into consideration the previous actions right because we just created The Matrix instance so let's do two iterations okay from approved and from approved I'll move to canceled I'm just doing some random things okay so two iterations are done now as per the definition of metric this action should get captured into metric acids let's see so how we can see that for that again we have to go to Matrix and under definition we have metric instances right this is where the actual data get captured so if I go and what was the name for the metric which you have created that's true it was what approval metric right approval so let's search it we got something for one and the answer is no so we have created a definition we have created a proper definition but it didn't work it didn't calculate it out what's the reason behind it so the reason behind its lie is with respect to one business rule okay so if I go to business rule hmm and if I go to business rules okay and I search this output metric so there is this business reward metric events right okay and as you can see it's on the task table only that's why it's doing all the calculation only on task table pretty bad right so if I want to use the same capability on approval table now in our use case okay how we can do that simple okay don't change this out okay don't you should not change out of the box uh definition anytime okay so we will give metric instance approval I'm telling you that you should not change and I'm changing it on and here I will select the table which was approval table and here I will do in certain stay so what it will do it will create it will not do any changes on this record it will create a replica of this record with the changes which you have just done so I'll do insert and stay so it will stay over there so this is a new business rule you don't believe me right ah let's see okay so I will go I will just copy this out the initial because the initial name should be the same is common right for the things so I will go over here and over here only let's go to the history business rows there was one with this name right now there should be two so you can see matter against a magnetic instead approval so I think this should they should be fine okay only this changes should make it happen okay let's see if something needs to be changed apart from this after we don't care about this and we don't care about the script because it's working on the task table okay so let's again go on what we can say on approval approvals let's take another record with the requester one and we'll follow the same thing what we did first we will approve and then we will cancel it out if it opens come on so this is a record now what I will do I will just change the state to uproot save and then we will change it to cancel save we'll go to metric instance again and I'm not against us okay this Matrix okay this this is how all the metric against it and now if I search for approval problematic metrics got calculated now okay perfect right okay so this is how it works okay and now you'll be thinking from where this no longer came right okay because a record has a change request has multiple records if you approve one record the other approval records will go to no longer State okay that's why this came okay so this is all for today's tutorial okay I find it pretty useful okay because I always use a matter against us okay this is the most significant way to track the things out okay to do validation based on the window and all those things out so in this way you can extend this capability from task table to non-taskable also so this is all for today's tutorial hope you like it out okay if you want to get notified with my future updates or future videos okay please subscribe to my channel and like this video okay till then stay safe stay happy and have a nice day at it thank you

View original source

https://www.youtube.com/watch?v=bwIQUkU3Dgo