Results 1 to 3 of 3
  1. #1
    Join Date
    May 2002
    Posts
    47

    Unanswered: spooloing sqllogs to event viewer

    Is there a way to spool sql logs to event viewer?

  2. #2
    Join Date
    Jan 2003
    Location
    México City
    Posts
    31

    Re: spooloing sqllogs to event viewer

    See xp_logevent item in BOL.
    César

  3. #3
    Join Date
    May 2002
    Posts
    47

    capturing failed logins to nt event log

    OK, I figured out how to log failed NT logins to a sql database but not failed sql accounts . any ideas?

    The syslogins table captures failed NT logins.

    DECLARE @@TABNAME varchar(30)
    DECLARE @@USERNAME varchar(30)
    DECLARE @@MESSAGE varchar(255)
    SET @@TABNAME = 'customers'
    SET @@USERNAME = USER_NAME()
    SELECT @@MESSAGE = 'The table ' + @@TABNAME + ' is not owned by the user
    ' + @@USERNAME + '.'

    USE master
    EXEC xp_logevent 60000, @@MESSAGE, informational

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •