Skip to main content
Nintex Community Menu Bar
Question

Where can I find transaction history for activities in workflow

  • May 26, 2026
  • 2 replies
  • 15 views

Forum|alt.badge.img+1

Hi guys! I would like to ask if you guys know where I can find the record transaction of activities in workflow in K2 database? I want to do audit trail for overview of activities in the workflow.

2 replies

Forum|alt.badge.img+1
The data in the table above is what I request for. Where can I find this information or transaction record of activities in K2 database? 

 


Arvindsct
Nintex Partner
Forum|alt.badge.img+2
  • Nintex Partner
  • May 27, 2026

Hello ​@AinaSyazzween ,

you can run below query to get it. 

 

SELECT 
    pi.Folio,
    ai.ID                               AS ActivityInstID,
    ad.[User]                           AS DestinationUser,
    CASE ai.Status
        WHEN 0 THEN 'Active'
        WHEN 1 THEN 'Complete'
        WHEN 2 THEN 'Sleep'
        WHEN 4 THEN 'Declined'
        ELSE CAST(ai.Status AS VARCHAR)
    END                                 AS Status,
    ai.StartDate                        AS Started,
    ai.FinishDate                       AS Finished,
    CASE 
        WHEN ai.FinishDate IS NULL OR ai.Status = 0 THEN
            CAST(DATEDIFF(HOUR, ai.StartDate, GETDATE()) / 24 AS VARCHAR) + 'd ' +
            CAST(DATEDIFF(HOUR, ai.StartDate, GETDATE()) % 24 AS VARCHAR) + 'h'
        ELSE
            CAST(DATEDIFF(HOUR, ai.StartDate, ai.FinishDate) / 24 AS VARCHAR) + 'd ' +
            CAST(DATEDIFF(HOUR, ai.StartDate, ai.FinishDate) % 24 AS VARCHAR) + 'h'
    END                                 AS Duration

FROM [ServerLog].[ActInst]          ai
INNER JOIN [ServerLog].[ActInstDest] ad  ON ad.ActInstID = ai.ID
                                        AND ad.ProcInstID = ai.ProcInstID
INNER JOIN [ServerLog].[ProcInst]   pi  ON pi.ID         = ai.ProcInstID


ORDER BY ai.StartDate DESC;


Feel free to reach out to us if you need any supports  Automate@proinception.com