The community will be in read-only from Monday 11:59pm (PT) to Wednesday 7:30am (PT)
The community will be in read-only from Monday 11:59pm (PT) to Wednesday 7:30am (PT)
Service Desk Practitioners Forum
cancel
Showing results for 
Search instead for 
Did you mean: 

DB Rule from one status from another

SOLVED
Go to solution
Highlighted
Luis Hernandez
Super Collector

DB Rule from one status from another

Hi.

I want to make a DB Rule which detects the status change from one status to another, lets say, from completed to close. It should only work when the source status is completed

Is it possible?

Thanx in advance.
4 REPLIES
Mark O'Loughlin
Honored Contributor

Re: DB Rule from one status from another

Hi,

have you had a look at creatinga DB rule setting the option to "Evalute this rule when this field has been changed" for the trigger which in this case seems to be when source status is completed.

Luis Hernandez
Super Collector

Re: DB Rule from one status from another

Hi, Mark.

The point is that I need to detect the exact transition from completed to close, not any status change.
George M. Meneg
Honored Contributor
Solution

Re: DB Rule from one status from another

Hello Luis,

It is possible but it's ugly. Create a custom text field named "existing status". Then, create a UI rule that when the item is opened to copy the status to "existing status".

Then create a db rule that when status is changed and new status="CLOSED" and "existing status=COMPLETED", do whatever you plan to.

Have in mind however that this rule can be overited if the status is changed two times using "Update All" or a db rule. The "existing status" will get its value every time the item is opened because it's ui rule. Update all updates items but will not trigger ui rules.
menes fhtagn
Luis Hernandez
Super Collector

Re: DB Rule from one status from another

Thanks, George.

Your way is the only way I have found to resolve this problem, but it's ugly and unsecure, due to the "update all" issue you mentioned.

It works, but I won't put it in production.
//Add this to "OnDomLoad" event