Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase

Logon triggers - using EVENTDATA() versus system functions (SUSER_SNAME() etc.) Expand / Collapse
Author
Message
Posted Tuesday, June 1, 2010 11:56 AM
SSCommitted

SSCommittedSSCommittedSSCommittedSSCommittedSSCommittedSSCommittedSSCommittedSSCommitted

Group: General Forum Members
Last Login: Thursday, November 20, 2014 10:24 AM
Points: 1,865, Visits: 3,620
Which is the preferred way of writing a logon trigger for basic user authentication?

Using the EVENTDATA() function and extracting the connection information from the XML or using system functions like this?

select HOST_NAME(),APP_NAME(),SUSER_SNAME(),USER_NAME(),SCHEMA_NAME()



__________________________________________________________________________________

Turbocharge Your Database Maintenance With Service Broker: Part 2
Turbocharge Your Database Maintenance With Service Broker: Part 1
Real-Time Tracking of Tempdb Utilization Through Reporting Services
Monitoring Database Blocking Through SCOM 2007 Custom Rules and Alerts
Preparing for the Unthinkable - a Disaster/Recovery Implementation
Post #930906
Posted Friday, June 4, 2010 12:02 AM
SSC Eights!

SSC Eights!SSC Eights!SSC Eights!SSC Eights!SSC Eights!SSC Eights!SSC Eights!SSC Eights!

Group: General Forum Members
Last Login: Monday, September 22, 2014 4:29 PM
Points: 871, Visits: 287
If it's just Logon Inforamtion you wish to capture then go for the System Functions.

I don't see the point of EVENTDATA() for your requirement. The System Functions will also perform better because the information is extracted from the SQL Srver's System Tables.



Kindest Regards,



Post #932593
« Prev Topic | Next Topic »

Add to briefcase

Permissions Expand / Collapse