dbo
|
04/26/2006 |
PRIMARY |
0 |
0 |
0 |
Audit table tracking errors in the the AdventureWorks database that are caught by the CATCH block of a TRY...CATCH construct. Data is inserted by stored procedure dbo.uspLogError when it is executed from inside the CATCH block of a TRY...CATCH construct. |
|
|
ErrorLogID |
int |
4 |
|
|
|
|
Primary key for ErrorLog records. |
|
|
ErrorTime |
datetime |
8 |
|
(getdate()) |
|
|
The date and time at which the error occurred. |
|
|
UserName |
sysname |
256 |
|
|
|
|
The user who executed the batch in which the error occurred. |
|
|
ErrorNumber |
int |
4 |
|
|
|
|
The error number of the error that occurred. |
|
|
ErrorSeverity |
int |
4 |
|
|
|
|
The severity of the error that occurred. |
|
|
ErrorState |
int |
4 |
|
|
|
|
The state number of the error that occurred. |
|
|
ErrorProcedure |
nvarchar |
126 |
|
|
|
|
The name of the stored procedure or trigger where the error occurred. |
|
|
ErrorLine |
int |
4 |
|
|
|
|
The line number at which the error occurred. |
|
|
ErrorMessage |
nvarchar |
4000 |
|
|
|
|
The message text of the error that occurred. |
Total: 9 column(s)
|
ErrorLogID |
1 |
1 |
|
Total: 1 index(es)
Total: 13 object(s)
CREATE TABLE [ErrorLog] (
[ErrorLogID] [int] IDENTITY (1, 1) NOT NULL ,
[ErrorTime] [datetime] NOT NULL CONSTRAINT [DF_ErrorLog_ErrorTime] DEFAULT (getdate()),
[UserName] [sysname] NOT NULL ,
[ErrorNumber] [int] NOT NULL ,
[ErrorSeverity] [int] NULL ,
[ErrorState] [int] NULL ,
[ErrorProcedure] [nvarchar] (126) COLLATE Latin1_General_CS_AS NULL ,
[ErrorLine] [int] NULL ,
[ErrorMessage] [nvarchar] (4000) COLLATE Latin1_General_CS_AS NOT NULL ,
CONSTRAINT [PK_ErrorLog_ErrorLogID] PRIMARY KEY CLUSTERED
(
[ErrorLogID]
) ON [PRIMARY]
) ON [PRIMARY]
GO
List of tables