How to find when and who stopped a Trigger in Production Environment

Hi all,
Would be greatful of some help with a DB Query relating to Triggers.
One of our important Triggers was disabled in Production sometime over the weekend and nobody is owning up to it :slight_smile:

Is there a query I can run against my SQL Database to give me the history of who stopped this Trigger?

Thanks,
JOhn.

1 Like

Hi @johnom

Please give the following query a try:

SELECT 
    [Time], [User], [Action], [TriggerName]
FROM 
    [dbo].[AuditLogs] 
WHERE 
    [Action] LIKE '%Trigger%'
    AND [TriggerName] = 'Trigger Name'
ORDER BY 
    [Time] DESC;

Hope this helps,
Best Regards.

@johnom

You can go to Audit logs in On-Prem UiPath Orchestrator

https://docs.uipath.com/orchestrator/standalone/2022.10/user-guide/about-audit

Hope this may help you

Thanks,
Srini

@arjunshenoy Thanks for this, however my auditlogs table doesn’t seem to have a column called TriggerName and the Action are numeric, not text.

Maybe it’s the version I’m on??

2021.10.4

@Srini84 - I don’t see this on my Orchestrator. Is this available on on-prem version 2021.10?

Hi @johnom

Well, in that case, you can try the following query as you mentioned the Action are numeric, not text:

SELECT 
    [Timestamp], [User], [Action], [Message]
FROM 
    [dbo].[ExecutionAuditData]
WHERE 
    [Action] IN (2, 3)
    AND [Message] LIKE '%INSERT_TRIGGER_NAME_HERE%'
ORDER BY 
    [Timestamp] DESC;

Comment → 2: Disabled, 3: Enabled

Hope this helps,
Best Regards.

@johnom

As per the documentation yes, Audit Page is there

Thanks,
Srini

Thanks everyone.
Got this query to work for me…

select dbo.auditlogs.
DisplayName,
ExecutionTime,
Parameters,
dbo.users.Name
from [xxrpa-prd].[dbo].[AuditLogs],
dbo.Users
where dbo.users.Id = dbo.AuditLogs.UserId
and DisplayName = ‘TRIGGER_NAME’
order by ExecutionTime desc

2 Likes