Skip to content

SQL-004: clsAppInfo.InsertSQL

This insert statement writes one application info or audit row to NetFramework.dbo.App_Info. It stores application and page context, machine and environment, user name, message text, data text, create date, and the 30-day purge date applied by the insert lifecycle.

Classification

Field Value
SQL ID SQL-004
Operation type Create
Execution method Inline
Database SQL Server
Schema NetFramework.dbo
Command type Text
Business object clsAppInfo
Criteria property InsertSQL
Lifecycle method BeforeInsert

Parameters

Parameter Direction Type Max length Description
@App_Name Input String 50 Application name from the audit payload or explicit overload argument.
@Create_Date Input DateTime N/A Audit timestamp.
@Environment Input String 50 Runtime environment name.
@Machine_Name Input String 50 Machine or host name that logged the audit message.
@Page_Name Input String 50 Page or request context name.
@Data_Text Input String DataText.Length Audit payload or detail text.
@Purge_Date Input DateTime N/A Retention cutoff set to 30 days after creation.
@User_Name Input String 50 User name associated with the audit event.
@Message_Text Input String 200 Audit message summary text.

Tables

Table Access Columns used
App_Info INSERT App_Name, Page_Name, Machine_Name, Environment, User_Name, Message_Text, Data_Text, Create_Date, Purge_Date

Sample SQL

INSERT INTO NetFramework.dbo.App_Info
           (App_Name
           ,Page_Name
           ,Machine_Name
           ,Environment
           ,User_Name
           ,Message_Text
           ,Data_Text
           ,Create_Date
           ,Purge_Date)
     VALUES
           (@App_Name
           ,@Page_Name
           ,@Machine_Name
           ,@Environment
           ,@User_Name
           ,@Message_Text
           ,@Data_Text
           ,@Create_Date
           ,@Purge_Date)

Operations and processes

Business rules

Sources

  • Application\SAIF.Application.LogView\clsAppInfo.vb