The mi_tab_spaceloc() accessor function

The mi_tab_spaceloc() function retrieves the location of the extspace in which the table resides.

Syntax

mi_string* mi_tab_spaceloc(MI_AM_TABLE_DESC *tableDesc)
tableDesc
Points to the table descriptor.

Usage

A user, usually a database server administrator, can assign a short name to an extspace with the onspaces utility. When a user creates a table, the CREATE TABLE statement can include an IN clause to specify one of the following:
  • The name that is assigned with the onspaces utility
  • A string that contains the actual location

To find out the string that the user specifies as the storage space, call the mi_tab_spaceloc() function.

For example, the mi_tab_spaceloc() function returns the string host=dcserver,port=39 for a storage space that the following commands specify:
onspaces -c -x dc39 -l "host=dcserver,port=39"
CREATE TABLE remote...
   IN dc39
   USING access_method

Return values

A string identifies the extspace.

If the table resides in an sbspace, this function returns a NULL-valued pointer.