-- Updated for SQL2000:
-- Table containing the lock request mode values and text.
if object_id('syslockreqmode') is not null and
        objectproperty( object_id('syslockreqmode') , 'IsUserTable' ) = 1
        drop table syslockreqmode
go
create table syslockreqmode (
req_mode int not null, req_mode_text varchar( 60 ) not null
);
insert syslockreqmode
SELECT  0 , 'NULL (No access is granted)'
UNION ALL
SELECT  1 , 'Sch-S (Schema stability)'
UNION ALL
SELECT  2 , 'Sch-M (Schema modification)'
UNION ALL
SELECT  3 , 'S (Shared)'
UNION ALL
SELECT  4 , 'U (Update)'
UNION ALL
SELECT  5 , 'X (Exclusive)'
UNION ALL
SELECT  6 , 'IS (Intent Shared)'
UNION ALL
SELECT  7 , 'IU (Intent Update)'
UNION ALL
SELECT  8 , 'IX (Intent Exclusive)'
UNION ALL
SELECT  9 , 'SIU (Shared Intent Update)'
UNION ALL
SELECT  10 , 'SIX (Shared Intent Exclusive)'
UNION ALL
SELECT  11 , 'UIX (Update Intent Exclusive)'
UNION ALL
SELECT  12 , 'BU (Bulk operations lock)'
UNION ALL
SELECT  13 , 'RangeS_S (Shared Key-Range and Shared Resource lock)'
UNION ALL
SELECT  14 , 'RangeS_U (Shared Key-Range and Update Resource lock)'
UNION ALL
SELECT  15 , 'RangeI_N (Insert Key-Range and Null Resource lock)'
UNION ALL
SELECT  16 , 'RangeI_S (Conversion lock, RangeI_N and S lock)'
UNION ALL
SELECT  17 , 'RangeI_U (Conversion lock, RangeI_N and U lock)'
UNION ALL
SELECT  18 , 'RangeI_X (Conversion lock, RangeI_N and X lock)'
UNION ALL
SELECT  19 , 'RangeX_S (Conversion lock, RangeI_N and S lock)'
UNION ALL
SELECT  20 , 'RangeX_U (Conversion lock, RangeI_N and U lock)'
UNION ALL
SELECT  21 , 'RangeX_X (Exclusive Key-Range and Exclusive Resource lock)' ;
go
-- Table containing the lock request type values and text.
if object_id('syslockreqtype') is not null and
        objectproperty( object_id('syslockreqtype') , 'IsUserTable' ) = 1
        drop table syslockreqtype
go

create table syslockreqtype ( 
req_type int not null, req_type_text varchar( 15 ) not null
);
insert into syslockreqtype
SELECT 1, 'NULL Resource'
UNION ALL
SELECT 2, 'Database'
UNION ALL
SELECT 3, 'File'
UNION ALL
SELECT 4, 'Index'
UNION ALL
SELECT 5, 'Table'
UNION ALL
SELECT 6, 'Page'
UNION ALL
SELECT 7, 'Key'
UNION ALL
SELECT 8, 'Extent'
UNION ALL
SELECT 9, 'RID (Row ID)'
UNION ALL
SELECT 10, 'Application'
go
This page was last updated on May 01, 2006 04:28 PM.