Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2005 Forums
 SQL Server Administration (2005)
 How ToGet Session IP Tru Web Service Endpoint?

Author  Topic 

howyue
Starting Member

2 Posts

Posted - 2007-04-03 : 00:03:37
i hav a endpoint in my sql 2005 sp2 that allow incoming connection from a thirdparty application, the thing is in my web method (storedproc) i wan to record the caller internet ip, internal ip(if the connection is coming from a network), host_name, nt_domain, nt_user_name & row_count how do i do that ? i tried the following sql,

Select c.session_id, connect_time, c.endpoint_id, client_net_address, client_tcp_port, host_name, program_name, login_name, nt_domain, nt_user_name, row_count
From sys.dm_exec_connections c
Join sys.dm_exec_sessions s On s.session_id = c.session_id
Where c.session_id = @@spid


but i couldn't get the internal ip, host_name, nt_domain, nt_user_name & row_count! it was ok if i directly execute the storedproc in query analyzer, but tru endpoint what i only get is empty string! any suggestion will be much appreciated! thank q.
   

- Advertisement -