How to report difference between a catalog item variable and catalog task closure date?

Sachin G K1
Kilo Sage

Hi All,

 

I have a catalog item "abc" with a variable called Termination Date. It generates one catalog task (sc_task). I want to create a report  that shows the difference between the Termination Date (from RITM variable) and the task's closure date. What’s the best way to achieve this?

 

 

Thanks in Advance,

Sachin

2 ACCEPTED SOLUTIONS

Ankur Bawiskar
Tera Patron
Tera Patron

@Sachin G K1 

1 easy way

1) store the termination date variable value in custom field on sc_task

2) then report on sc_task table and use function field to find the difference between the variable and task closure date/time

Function Fields in ServiceNow Reports: Calculate and Display Data on the Fly 

If my response helped please mark it correct and close the thread so that it benefits future readers.

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

View solution in original post

@Sachin G K1 

don't show that field on form, remove it from form view

You can enhance the BR to work only for particular sc task

For older records you can use fix script to update the custom field with variable value.

I believe I have answered your question with the approach and you can take it further from here.

If my response helped please mark it correct and close the thread so that it benefits future readers.

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

View solution in original post

6 REPLIES 6

if i create the custom field in sc_task, this field will be visible in all sc_task right, instead i need it in only sc_task whose assigned to "Abel" also, bbr will work for upcoming records and not for older ones, how to deal with this

@Sachin G K1 

don't show that field on form, remove it from form view

You can enhance the BR to work only for particular sc task

For older records you can use fix script to update the custom field with variable value.

I believe I have answered your question with the approach and you can take it further from here.

If my response helped please mark it correct and close the thread so that it benefits future readers.

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader