-
Code Help: I would the network user name.
Using Transact SQL how can I retrieve the network user name by accessing the API apiGetUserName.
I would like to some how create a stored procedure that will retrieve the user name when a user tries to access the data in a table(s).
-
I'm not sure of the API... But you can try "SELECT loginame from master.dbo.sysprocesses (nolock) where spid = @@spid".
HTH
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
|