I'm blocking problem in sqlserver caused by cursor.
The head block I see is a fatch_api_cursor, the problem is that when I try to see the SQL code inside the cursor, it shows nothing and the status is like sleeping.
any idea how I can detect what is inside the cursor?
I've tried to dmv sys.dm_exec cursors but does not provide any information.
I have to kill the process to release the locks.