We've updated the ServiceNow Community Code of Conduct, adding guidelines around AI usage, professionalism, and content violations. Read more

RiteshSwarnakar
Giga Guru

Scenario: There are two tables Books and Bookstore. Bookstore contains Store Name, Owner, Location and reference to Books table for Available books.

We need to calculate & update the total price of selected book's and that should reflect in Service Catalog in real time. So as the books are selected or removed the Total Price changes accordingly in Service Catalog.

 

1] Books Table:

find_real_file.png

 

2] Bookstore Table:

find_real_file.png

 

 

3] Service Catalog:

find_real_file.png

 

 

4] Client Script:

find_real_file.png

 

5] Script Include:

find_real_file.png

 

 

 

Regards,

Ritesh Swarnakar

Comments
Maryna K
Tera Contributor

I’m leaving my solution for this case in case it is helpful for someone.

 

You need to set Price implication for the variable in the Catalog to true. This way, the price will be calculated automatically based on the values added to the List Collector variable.

 

Here is the link to the documentation: Using variables for price setup

 

If you found this message helpful, please mark my answer as Helpful.

Version history
Last update:
‎05-23-2022 03:00 AM
Updated by: