You are viewing limited content. For full access, please sign in.

Question

Question

Table containing [event_type] Descriptions

asked on June 24, 2020

In trying to run queries directly off the [audit_event] table in the AuditTrail database, we are provided with an [event_type] field. 

While the descriptions of these are provided in the help files, it makes writing a large, dynamic query difficult, as you must also write a case statement for each of the [event_type] values returned so that they display their description (e.g. display "Log On" instead of 1, "View Document" instead of 34, ...).  Normally we'd just join the table with another where those descriptions were housed so that they would dynamically show the corresponding description, however I cannot find a table that houses these.  I know the AuditTrail site when it displays reports does show the description for the event instead of the number but I am wondering if that logic is hard-coded into the site and thus there is not a table available.

Has anyone found in the AuditTrail database where the descriptions for the [event_type] are stored?  If they do not exist there then I would have to build a custom table that houses that info to do the joins and that seems like a waste when it should be in the actual database already.

0 0

Answer

SELECTED ANSWER
replied on June 24, 2020

They're not stored in the database.

1 0
replied on June 24, 2020

That's what I figured but wanted to make sure.  I will just build a SQL table and import them in so I can do the join.  Can this be added as a request for future AuditTrail versions so that our queries can be more dynamic without needing to create custom tables?

1 0
replied on June 25, 2020

Probably not. The event names are dependent on the UI language, so they're in the website's localized resources. Moving them to SQL would add unnecessary overhead to upgrades and such.

0 0
replied on June 25, 2020

Makes sense. Thanks for the quick info!

0 0

Replies

replied on June 24, 2020 Show version history

I use a table of description that I found on an Answers post.  Sorry I can't seem to find the post though.  See Attached.

EventDesc.xlsx (12.43 KB)
0 0
You are not allowed to follow up in this post.

Sign in to reply to this post.