Question

I created a trigger for auditing purposes that logs changes made to a particular table.

Is there any way for me to tell what computer the query that set the trigger off came from? I have full access to the database, but no access to software code.

Was it helpful?

Solution

I'd include these in your auditing:

SELECT 
    HOST_NAME()  ModifiedByHost, 
    SYSTEM_USER  ModifiedByUser,
    APP_NAME()  ModifiedByAppName

HOST_NAME() will give you the computer.

http://technet.microsoft.com/en-us/library/ms178598.aspx

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top