systhresholds

All databases

Description

systhresholds contains one row for each threshold defined for the database.

Columns

The columns for systhresholds are:

Name

Datatype

Description

segment

smallint

Segment number for which free space is being monitored.

free_space

int

Size of threshold, in logical pages.

status

smallint

Bit 1 equals 1 for the log segment’s last-chance threshold, 0 for all other thresholds.

proc_name

varchar(255)

Name of the procedure that is executed when the number of unused pages on segment falls below free_space.

suid

int null

The server user ID of the user who added the threshold or modified it most recently.

currauth

varbinary(255) null

A bitmask that indicates which roles were active for suid at the time the threshold was added or most recently modified. When the threshold is crossed, proc_name executes with this set of roles, less any that have been deactivated since the threshold was added or last modified.

Determining the active roles from currauth The following table lists the possible bitmasks you might see, individually or in combination, in the currauth column.

Decimal

Hex

Description

1

0x1

sa_role

2

0x2

sso_role

4

0x4

oper_role

8

0x8

sybase_ts_role

16

0x10

sybase_ts_role

32

0x20

navigator _ole

128

0x80

replication_role

256

0x100

dtm_tm_role

1024

0x400

ha_role

2048

0x800

mon_role

4096

0x1000

js_admin_role

16384

0x4000

messaging_role

32768

0x8000

web_services

To find out what role ID is associated with the bitmask output in currauth in your Adaptive Server, perform the following select statement:

1> select (c.number - 1) as role_id,role_name(c.number - 1) as role_name
2> from systhresholds ,master.dbo.spt_values c
3> where   convert(tinyint,substring(isnull(currauth,0x1), c.low,1)) &
4> c.high != 0
5> and c.type = "P"
6> and c.number <= 1024
7> and c.number >0
8> and role_name(c.number - 1) is not null
9> go

Adaptive Server returns something similar to the following:

 role_id     role_name
----------- ------------------------------
           0 sa_role
           1 sso_role
           2 oper_role
           3 sybase_ts_role
           4 navigator_role
           7 dtm_tm_role
          10 mon_role
          11 js_admin_role
          12 messaging_role
          13 js_client_role