SQL-003: clsAppError.InsertSQL
This insert statement writes one application error row to NetFramework.dbo.App_Error. It captures application name, timestamp, environment, machine/page context, source, state information, error text, and user name before the identity value is read back by SQL-001 .
Classification
Field
Value
SQL ID
SQL-003
Operation type
Create
Execution method
Inline
Database
SQL Server
Schema
NetFramework.dbo
Command type
Text
Business object
clsAppError
Criteria property
InsertSQL
Lifecycle method
BeforeInsert
Parameters
Parameter
Direction
Type
Max length
Description
@App_Name
Input
String
50
Application name from the error payload or explicit overload argument.
@Error_Date
Input
DateTime
N/A
Error timestamp.
@Environment
Input
String
50
Runtime environment name.
@Machine_Name
Input
String
50
Machine or host name that logged the error.
@Page_Name
Input
String
50
Page or request context name.
@Error_Source
Input
String
50
Exception source identifier.
@State_Info
Input
String
StateInfo.Length
Serialized state or context text.
@Error_Info
Input
String
ErrorInfo.Length
Detailed error text.
@User_Name
Input
String
50
User name associated with the error event.
Tables
Table
Access
Columns used
App_Error
INSERT
App_Name, Error_Date, Environment, Machine_Name, Page_Name, Error_Source, State_Info, Error_Info, User_Name
Sample SQL
INSERT INTO NetFramework . dbo . App_Error
( App_Name
, Error_Date
, Environment
, Machine_Name
, Page_Name
, Error_Source
, State_Info
, Error_Info
, User_Name
)
VALUES
( @ App_Name
, @ Error_Date
, @ Environment
, @ Machine_Name
, @ Page_Name
, @ Error_Source
, @ State_Info
, @ Error_Info
, @ User_Name
)
Operations and processes
Business rules
Sources
Application\SAIF.Application.LogView\clsAppError.vb