SQL Server/T-SQL Tutorial/System Tables Views/sysmessages

Материал из SQL эксперт
Версия от 10:24, 26 мая 2010; Admin (обсуждение | вклад) (1 версия)
(разн.) ← Предыдущая | Текущая версия (разн.) | Следующая → (разн.)
Перейти к: навигация, поиск

list all the defined messages in sysmessages

6>
7>
8> SELECT top 10 error, severity, description
9> FROM master..sysmessages
10> ORDER BY error
11> GO
error       severity description
----------- -------- -----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
----------------------------------------------------------------------------
         21       20 Warning: Fatal error %d occurred at %S_DATE. Note the error and time, and contact your system administrator.
        101       15 Query not allowed in WAITFOR.
        102       15 Incorrect syntax near "%.*ls".
        103       15 The %S_MSG that starts with "%.*ls" is too long. Maximum length is %d.
        104       15 ORDER BY items must appear in the select list if the statement contains a UNION, INTERSECT or EXCEPT operator.
        105       15 Unclosed quotation mark after the character string "%.*ls".
        106       16 Too many table names in the query. The maximum allowable is %d.
        107       15 The column prefix "%.*ls" does not match with a table name or alias name used in the query.
        108       15 The ORDER BY position number %ld is out of range of the number of items in the select list.
        109       15 There are more columns in the INSERT statement than values specified in the VALUES clause. The number of values in the VALUES clause must match the number of columns specified in
the INSERT statement.
(10 rows affected)