The CreatorCon Call for Content is officially open! Get started here.

How to update the Life cycle stage and Life cycle status stage fields if CI is retired?

Laxmi Palamarth
Tera Contributor

Hi,

I have a requirement to update the fields "Life cycle state" and "Life cycle state stage" fields should be updated to "End of Life" and "Retired" simultaneously if a CI is moved to Retired state. If the install status is changed from "Retired" to any other state, Life cycle state and stage should be emptied.  For this I have written a Business rule on cmdb_ci table, which is not working. Can anyone let me know why the fields were not updating with the below script?

LaxmiPalamarth_0-1676378772320.png

LaxmiPalamarth_1-1676378802156.png

 

 

1 REPLY 1

emir
ServiceNow Employee
ServiceNow Employee

clearValue is for GlideForm, you are working with GlideRecord here. 

You are also not updating the record in the else block.

there is a lifecycle mapping, that you should use instead.