SQL/MX 3.2.1 Management Manual (H06.26+, J06.15+)

c.object_uid = o.object_uid and
column_name = 'ORDERNUM' and
o.object_type = 'BT' and
o.schema_uid =
(select schema_uid
from nonstop_sqlmx_<sys name>.system_schema.schemata
where
schema_name = 'SALES' and
cat_uid =
(select cat_uid
from nonstop_sqlmx_<sys name>.system_schema.catsys
where cat_name = 'SAMDBCAT'
)
)
for read uncommitted access;
TABLE_NAME
--------------------
SQL_DATA_TYPE
------------------
COLUMN_NAME
--------------------
ODETAIL
ORDERS
UNSIGNED NUMERIC
UNSIGNED NUMERIC
ORDERNUM
ORDERNUM
Displaying Information About Privileges
Topics in this subsection:
“Displaying all Privileges for a Table” (page 144)
“Displaying all Privileges for a View” (page 145)
“Displaying all Privileges for a Column” (page 146)
The TBL_PRIVILEGES table, located in the schema
DEFINITION_SCHEMA_VERSION_version-number of each catalog, describes the privileges
for all tables and views in that catalog. The COL_PRIVILEGES table, located in the schema
DEFINITION_SCHEMA_VERSION_version-number of each catalog, describes the privileges
for all columns in that catalog. For more information about all metadata tables, see Figure 3
(page 109) in this manual or the SQL/MX Reference Manual.
All queries for information about privileges must access information from the CATSYS, SCHEMATA,
and OBJECTS tables, and from other appropriate tables, such as the TBL_PRIVILEGES table.
The SHOWDDL command does not display information about privileges.
Displaying all Privileges for a Table
This example displays all privileges for the table SAMDBCAT.SALES.ORDERS:
>>set schema samdbcat.definition_schema_version_<schema version>;
--- SQL operation complete.
>> select grantor as grantor_id,
case (grantor_type)
when 'S' then 'System'
when 'U' then 'User'
else 'Unknown'
end as grantor_t,
grantee as grantee_id,
case (grantee_type)
when 'P' then 'Public'
when 'U' then 'User'
else 'Unknown'
end as grantee_t,
case (privilege_type)
when 'S' then 'Select'
when 'I' then 'Insert'
144 Querying SQL/MX Metadata