SHOW object SQL Statement | Teradata Vantage - SHOW object - Advanced SQL Engine - Teradata Database

SQL Data Definition Language Syntax and Examples

Product
Advanced SQL Engine
Teradata Database
Release Number
17.05
Published
January 2021
Language
English (United States)
Last Update
2021-01-22
dita:mapPath
ncd1596241368722.ditamap
dita:ditavalPath
hoy1596145193032.ditaval
dita:id
B035-1144
lifecycle
previous
Product Category
Teradata Vantage™

For tables, macros and views, displays the SQL data definition text for the original create text from DBC.TVM.RequestText.

For information on displaying statistics information, see SHOW STATISTICS.

ANSI Compliance

The following statements and associated options are Teradata extensions to the ANSI SQL:2011 standard:
  • SHOW AUTHORIZATION
  • SHOW CAST
  • SHOW CONSTRAINT
  • SHOW ERROR TABLE FOR
  • SHOW FUNCTION
  • SHOW GLOP SET
  • SHOW HASH INDEX
  • SHOW JOIN INDEX
  • SHOW MACRO
  • SHOW METHOD
  • SHOW PROCEDURE
  • SHOW SPECIFIC FUNCTION
  • SHOW SPECIFIC METHOD
  • SHOW TABLE error_table_name
  • SHOW TABLE table_name
  • SHOW TRIGGER
  • SHOW TYPE
  • SHOW VIEW

Required Privileges

The following privileges are required to run a SHOW request against the specified objects.

To use SHOW ERROR TABLE FOR, SHOW FUNCTION, SHOW HASH INDEX, SHOW JOIN INDEX, SHOW MACRO, SHOW PROCEDURE, SHOW TABLE, or SHOW VIEW, you must have one of the following privileges:
  • Any privilege on the user-defined function, hash index, join index, macro, SQL procedure, GLOP set, table, or view, or any privilege on the database containing it.
  • At least one privilege on the DBC.TVM table.
  • SHOW FUNCTION for an SQL function requires any privilege on the function or its containing database or the SELECT privilege on the DBC.TVM table.

To use SHOW FUNCTION to show the C source code text for an external UDF, you must also have the DROP privilege on the function; otherwise, you can only display the CREATE FUNCTION text.

You do not need the DROP privilege on the function to show the SQL source code text for an SQL UDF.

To use SHOW CAST, SHOW TYPE, SHOW METHOD, or SHOW SPECIFIC METHOD, you must have one of the following privileges.
  • At least one privilege on the SYSUDTLIB database.
  • The UDTUSAGE privilege on the UDT.
  • The SELECT privilege on the DBC.TVM table.

To use SHOW CONSTRAINT, you must have either the CONSTRAINT DEFINITION or CONSTRAINT ASSIGNMENT privilege.

To use SHOW AUTHORIZATION, you must have the DROP AUTHORIZATION privilege on the authorization object.

Use the SHOW privilege to enable a user to perform HELP or SHOW requests only against the specified database object.