Recalculate incorrect SLAs on closed tickets

fghysens
Kilo Explorer

Hello

We had a wrong SLA setup causing incorrect sla results.   The SLA setup is now corrected.

Is there a way to recalculate my SLA results (task_sla) on the closed tickets that were related to the wrong sla setup?

Any ideas are welcome.

Thanks

f

2 REPLIES 2

jbauguess
Tera Expert

I'm doing the same thing right now.   Got a couple of hours to run a script?   Because that's how long this'll take.   I'm updating over 200,000 records though:



1. Copy this script include into your instance.


2. In background scripts, run new SLARunner().__updateEverySLAEver();


3. Wait...(again, it took 2 hours for this to run for my 216,056 records)


4. And you're done.



If you're not using the "newer" SLA engine, you'll need to trade out SLACalculatorNG for SLACalculator.   (My instance uses the newer one, which is why I didn't condition that in the code.)   You can also modify the conditions on the task_sla query to better meet your needs, if necessary.


Hi Justin



Thanks for the quick reply, our admins will review this!