Solved

client ip address connected to sql server

Posted on 2009-03-31
4
628 Views
Last Modified: 2012-05-06
I have problem to find Current IP address for client computer that have a connection to Specific DataBase Server .I need to find out current client user IP address that I am seeking to find it
,How can I do this by using T-SQL command?
Please write full T-SQL code .
0
Comment
Question by:help_me_programming
  • 2
4 Comments
 
LVL 142

Expert Comment

by:Guy Hengel [angelIII / a3]
Comment Utility
please provider the table structure, and the input value/field...
0
 

Author Comment

by:help_me_programming
Comment Utility
this is a generic question about client ip connection
0
 
LVL 142

Accepted Solution

by:
Guy Hengel [angelIII / a3] earned 500 total points
Comment Utility
i see.
you want to look in the master.sys.sessions table (sql 2005+) resp: master.dbo.syssessions (sql 2000), the field hostname will give the computer name (or eventually the ip address).

to resolve the name into a ip address is "not possible" built-in in sql server.
for the current session, the function hostname() returns the info also.
0

Featured Post

Do You Know the 4 Main Threat Actor Types?

Do you know the main threat actor types? Most attackers fall into one of four categories, each with their own favored tactics, techniques, and procedures.

Join & Write a Comment

When you hear the word proxy, you may become apprehensive. This article will help you to understand Proxy and when it is useful. Let's talk Proxy for SQL Server. (Not in terms of Internet access.) Typically, you'll run into this type of problem w…
Let's review the features of new SQL Server 2012 (Denali CTP3). It listed as below: PERCENT_RANK(): PERCENT_RANK() function will returns the percentage value of rank of the values among its group. PERCENT_RANK() function value always in be…
Using examples as well as descriptions, and references to Books Online, show the different Recovery Models available in SQL Server and explain, as well as show how full, differential and transaction log backups are performed
Viewers will learn how to use the SELECT statement in SQL and will be exposed to the many uses the SELECT statement has.

771 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

16 Experts available now in Live!

Get 1:1 Help Now