A  B  C  D  E  F  G  H  I  J  K  L  M  N  O  P  Q  R  S  T  U  V  W  X  Y  Z  special characters  sybase-tech-blog


Category: ASE: Functions: System Functions

reserved_pgs()

The system function reserved_pgs() returns the number of server pages allocated to a table or index. The return value also includes pages, used for ASE internal structures. The system function "reserved_pgs()" is replaced with the function reserved_pages() starting with ASE version 15.0. The function "reserved_pgs()" can be executed by any user, but only on objects in the current database.

Syntax of the System Function reserved_pgs()

    reserved_pgs(object_id, {doampg | ioampg})
    

The parameters of the System Function reserved_pgs()

"object_id"
The parameter "object_id" describes the identification number of the table to be queried. The "object_id" is located in the column id of the system table sysobjects. "doampg|ioampg"
The function "reserved_pgs()" is used in queries on the columns "doampg" or "ioampg" of the system table sysindexes. The parameters "doampg" or "ioampg" determine if a table ("doampg"), or an index ("ioampg") is queried.

Example for the System Function reserved_pgs()

    select reserved_pgs(id, doampg)
    from sysindexes where id = 
    object_id("syslogs")

    -------------
             534 

    

The return value is the number of pages allocated to the system table syslogs.

See also:

ASE T-SQL - Aggregate Functions,
audit_event_name(),
col_length(),
col_name(),
curunreservedpgs(),
datachange(),
datalength(),
data_pages(),
data_pgs(),
db_id(),
db_name(),
host_id(),
host_name(),
identity(),
index_col(),
index_colorder(),
isnull(),
lct_admin(),
license_enabled(),
lockscheme(),
next_identity(),
object_id(),
object_name(),
pagesize(),
pointer_size(),
ptn_data_pgs(),
reserved_pages(),
rowcnt(),
row_count(),
showplan_in_xml(),
syb_sendmsg(),
syb_sendmsg(),
System Functions,
tempdb_id(),
tran_dumpable_status(),
tsequal(),
used_pages(),
used_pgs().