Available in: Logi Info | Source code name: LogEvent |
Defines event logging for a particular event.
Set the EventName to the event to be logged.
If desired, filter the events to a particular ElementID.
When an event is to be logged, a Process definition gets called with a number of parameters. Typically, the Process runs a Procedure.SQL that will insert a row into a log table defined in a database.
The Process can use a number of @Request parameters. Here's an example of a INSERT command from a Procedure.SQL that could insert a row into a log table:
INSERT INTO MYLOG (ActionName, ActionTimeStamp, SessionID) VALUES ('@Request.EventName~', '@Request.EventTime~', '@Session.SessionID~')
The @Request parameters available for each logged event depends on the EventName.
EventName: RunSQL Attributes: EventName: "RunSQL" ElementID: The name of the element that caused the event. EventTime: The time, in the format yyyy-MM-dd HH:mm:ss EventTimePrecise: The time, including milliseconds. EventDuration: The event duration in milliseconds. SQL: The SQL command. RowCount: The number of rows returned by the SQL query. Only available with DataLayer.SQL, not Procedure.Sql
EventName: RunSP Attributes: EventName: "RunSP" ElementID: The name of the element that caused the event. EventTime: The time, in the format yyyy-MM-dd HH:mm:ss EventTimePrecise: The time, including milliseconds. EventDuration: The event duration in milliseconds. SP: The SP command name RowCount: The number of rows returned by the SQL query. Only available with DataLayer.SQL, not Procedure.Sql SP Parameters: An @Request for each parameter of the SP. Like: @Request.myParameter1~
AuthenticateUser EventName: "AuthenticateUser" ElementID: The name of the element that caused the event. EventTime: The time, in the format yyyy-MM-dd HH:mm:ss EventTimePrecise: The time, including milliseconds. EventDuration: The event duration in milliseconds.
SessionStart EventName: "SessionStart" EventTime: The time, in the format yyyy-MM-dd HH:mm:ss EventTimePrecise: The time, including milliseconds.
BuildReport EventName: "BuildReport" EventTime: The time, in the format yyyy-MM-dd HH:mm:ss EventTimePrecise: The time, including milliseconds. EventDuration: The event duration in milliseconds. ReportID: The ID of the report definition.
|