web
You’re offline. This is a read only version of the page.
close
Skip to main content
Community site session details

Community site session details

Session Id :
Microsoft Dynamics AX (Archived)

How to indentify my SPID from SQL SERVER in order to kill it?

(0) ShareShare
ReportReport
Posted on by

Dear all,

I am not able to see my process. This process has been raised from AOT inside AX, it is just an export all the tables tree.

How can I distinguish amongst other running processes up?

Filtering by the following hostname I find lots of connections.

SELECT * FROM SYS.SYSPROCESSES
WHERE SPID > 50
AND hostname = 'CH001AOS01T'

*This post is locked for comments

I have the same question (0)
  • Martin Dráb Profile Picture
    236,353 Most Valuable Professional on at
    RE: How to indentify my SPID from SQL SERVER in order to kill it?

    Look at Finding User Sessions from SPID in Dynamics AX 2012.

  • Community Member Profile Picture
    on at
    RE: How to indentify my SPID from SQL SERVER in order to kill it?

    Thanks for your reply Martin. My concern is when you read this:

    [...]has a small performance overhead

    is there no another way to grasp who is who by using some DMVs or DMO?

    In Dynamics AX 2012, information about the user sessions can be directly included in the SQL connection context. Adding  this information has a small performance overhead. Therefore, it is not turned on by default. To include user session information in the connection context perform the following steps:

    1.Navigate to HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\services\Dynamics Server\6.0\01\Original (installed configuration). The last key, Original (installed configuration), is the key name for the current server configuration. If your system uses a different configuration that the original installed configuration, navigate to the currently active configuration.

    2.Create a string registry value called ‘connectioncontext’ and set the value to 1.

    3.Restart the AOS.

    Next open SQL Server Management Studio and run the following query to look at all the sessions related to Microsoft Dynamics AX:

  • Martin Dráb Profile Picture
    236,353 Most Valuable Professional on at
    RE: How to indentify my SPID from SQL SERVER in order to kill it?

    What's connecting to SQL Server is the AOS account - SQL Server has no information about AX users unless AX explicitly sends such information. That's what the parameter enables.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Abhilash Warrier – Community Spotlight

We are honored to recognize Abhilash Warrier as our Community Spotlight honoree for…

Leaderboard > 🔒一 Microsoft Dynamics AX (Archived)

#1
Martin Tocauer Profile Picture

Martin Tocauer 4

#1
Community Member Profile Picture

Community Member 4

#3
Nayyar Siddiqi Profile Picture

Nayyar Siddiqi 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans