It doesn't appear to be LockObjectOID or mutex_semaphore_id; those return zero rows.

ALTER PROCEDURE "dbo"."sp_list_mutexes_semaphores"( 
  in "oid" unsigned bigint default null ) 
result( 
  "mutex_semaphore_id" unsigned integer,
  "creator" varchar(128),
  "name" varchar(128),
  "type" char(9),
  "is_temp" char(1),
  "is_dropped" char(1),
  "start_with" unsigned integer,
  "current_count" unsigned integer,
  "currently_owned_by" long varchar,
  "currently_waited_for" long varchar ) 
sql security invoker
internal name 'sp_list_mutexes_semaphores'

SELECT Number, Name, BlockedOn, LockRowID, LockIndexId, LockTable, LockObject, LockObjectType,
       CONNECTION_PROPERTY ( 'LockObjectOID', Number ) AS LockObjectOID,
       CONNECTION_PROPERTY ( 'LockObjectType', Number ) AS LockObjectType
  FROM sa_conn_info()
 ORDER BY Number;
SELECT * FROM sp_list_mutexes_semaphores();
SELECT * FROM sp_list_mutexes_semaphores ( 3764 );
SELECT * FROM sp_list_mutexes_semaphores ( 2 );

     Number Name                             BlockedOn            LockRowID LockIndexId LockTable                      LockObject                     LockObjectType                 LockObjectOID                  LockObjectType                 
          1 consumer-1                               0                    0      (NULL)                                dba.test_semaphore             33                             3764                           33                             
          2 consumer-2                               0                    0      (NULL)                                dba.test_semaphore             33                             3764                           33                             
          3 producer                                 0                    0      (NULL)                                                               0                              0                              0                              
          4 SQL Central 1                            0                    0      (NULL)                                                               0                              0                              0                              
          5 Foxhound-Monitor-9384                    0                    0      (NULL)                                                               0                              0                              0                              
(5 rows)

mutex_semaphore_id creator                        name                           type      is_temp is_dropped start_with current_count currently_owned_by             currently_waited_for           
                 2 dba                            test_semaphore                 SEMAPHORE N       N                   0             0 (NULL)                         2,1                            
(1 rows)

mutex_semaphore_id creator                        name                           type      is_temp is_dropped start_with current_count currently_owned_by             currently_waited_for           
(0 rows)

mutex_semaphore_id creator                        name                           type      is_temp is_dropped start_with current_count currently_owned_by             currently_waited_for           
(0 rows)

asked 18 Nov '15, 08:15

Breck%20Carter's gravatar image

Breck Carter
26.2k430600864
accept rate: 20%

edited 18 Nov '15, 08:17


oid is a shortcut for getting information about a single temporary mutex/semaphore, for use by system procedures. It is not intended for general use.

permanent link

answered 18 Nov '15, 09:46

Elmi%20Eflov's gravatar image

Elmi Eflov
7811014
accept rate: 31%

Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×4

question asked: 18 Nov '15, 08:15

question was seen: 291 times

last updated: 18 Nov '15, 09:46