如何在SQL Server Profiler中找到客户机进程ID ?

时间:2021-11-05 08:29:28

I am using SQL Server Profiler to view my database activities. In that, I want to find out which Client Process ID is associate with which machine (From where application is running). because there are multiple instance of my application are running on different machines. So I want to identify them. So is there any way to find out ClientProcessID?

我正在使用SQL Server Profiler查看我的数据库活动。在这里,我想找出哪个客户端进程ID与哪个机器相关联(从应用程序运行的地方)。因为我的应用程序有多个实例在不同的机器上运行。所以我想找出它们。那么有没有办法找出客户流程呢?

1 个解决方案

#1


5  

you can use hostname in profiler, it is the same as the host_name() function in T-SQL

可以在profiler中使用hostname,它与T-SQL中的host_name()函数相同

run this in a query window

在查询窗口中运行它

SELECT host_name()

In profiler it is hostname, you have to check "show all columns" to see it

在profiler中,它是hostname,您必须检查“show all columns”才能看到它

#1


5  

you can use hostname in profiler, it is the same as the host_name() function in T-SQL

可以在profiler中使用hostname,它与T-SQL中的host_name()函数相同

run this in a query window

在查询窗口中运行它

SELECT host_name()

In profiler it is hostname, you have to check "show all columns" to see it

在profiler中,它是hostname,您必须检查“show all columns”才能看到它