sysdatabases

Provides information about databases on the SAP ASE server.

Name Datatype Description
name sysname A database name.
dbid smallint The database ID.
suid int The server user ID of the database owner.
status smallint Control bits that define the database state and options.
status5 int The database status.
The possible values are:
  • 0x00000001 – Encrypted.
  • 0x00000002 – Encryption in progress.
  • 0x00000004 – Decryption in progress.
  • 0x00000008 – Partially encrypted either due to an error or because the process was suspended by the user.
  • 0x00000010 – Partially decrypted either due to an error or because the process was suspended by the user.
  • 0x00000100 – The imrscache column stores the name of the default IMRS cache for the database.
  • 0x00000200 – Database-wide snapshot isolation and MVCC are enabled.
  • 0x00000400 – Database-wide DRC is enabled.
  • 0x00000010 – Partially decrypted either due to an error or because the process was suspended by the user.
  • 0x00001000 – Database-wide on-disk versioning is enabled.
  • 0x00004000 – Version storage is enabled and a valid temporary database name is configured.
  • 0x00010000 – ILM partition tuning is enabled.
version smallint Not used.
logptr int A pointer to the transaction log.
crdate datetime The date and time when the database was created.
dumptrdate datetime The date and time of the last transaction log dump.
status2 smallint An additional control bit.
audflags int The audit settings for the database.
deftabaud int A bit mask that defines default audit settings for tables.
defvwaud int A bit mask that defines default audit settings for views.
defpraud int A bit mask that defines default audit settings for stored procedures.
def_remote_type smallint The default object type used for remote tables when no storage location is specified through the sp_addobjectdef stored procedure.
def_remote_loc varchar(349) The default storage location used for remote tables when no location is specified through the sp_addobjectdef stored procedure.
status3 int Additional control bits used by the server.
status4 int Additional control bits for the database.
audflags2 varbinary(16) Reserved for future use.
instanceid tinyint In Cluster Edition, the ID of the instance that owns the local temporary database.
NULL – For other databases.
In non-clustered editions, the column is reserved for future use.
inrowlen smallint The maximum in-row length allowed for LOB columns across the database.
dcompdefaultlevel tinyint The default compression level applied when running create table, alter table, or reorg rebuild.
durability int The durability level configured for the database.
The possible values are:
  • 1 – full.
  • 5 – at_shutdown.
  • 6 – no_recovery.
lobcomp_lvl tinyint The compression level applied to LOB data.
encrkeyid int The ID of the database encryption key.
NULL – A non-encrypted database.
imrscache varchar(255) The name of the row storage cache assigned to the database.
imrslogptr int A pointer to the start of imrslog.
imrsloglastptr int A pointer to the end of imrslog.
versiondbid smallint The ID of the temporary database used for version storage in on-disk MVCC-enabled databases.