RDBPROD: What are the equivalent of Rdb's SHOW commands in SQLPLUS?
(Doc ID 738152.1)
Last updated on NOVEMBER 24, 2024
Applies to:
Oracle Rdb Server on OpenVMS - Version 7.0 and laterInformation in this document applies to any platform.
Purpose
What are the equivalent of Rdb's SHOW commands in SQLPLUS?
Typically in SQLPLUS you are required to interrogate tables to understand metadata objects. There are a set of tables usually prefixed ALL_ or USER_. Unless you want to look specifically within your own schema use the ALL_ tables. It may be necessary to prefix ALL_ with SYS.ALL_.
An RDB database is usually single schema whereas an RDBMS will always be multi-schema with references to OWNERs. See SQL(PLUS)>select username from all_users where username != 'SYS' and username != 'SYSTEM';
Because of the length of some columns it may be necessary to use the following commands to improve the display in sqlplus for example:
The purpose of this article is to list commands that would be useful in understanding objects related to tables. These include the following:
A) SQL> SHOW TABLES
B) SQL> SHOW TABLE(COLUMN) <TABLE_NAME>
C) SQL> SHOW INDEX
D) SQL>SHOW INDEX <INDEX_NAME>
E) SQL> SHOW TABLE(INDEX) <TABLE_NAME>
F) SQL> SHOW TABLE(COMMENT) <TABLE_NAME>
G) SQL> SHOW VIEWS
H) SQL> SHOW VIEW <VIEW_NAME>
I) SQL> SHOW TABLE(CONSTRAINT) <TABLE_NAME>
J) SQL> SHOW PROTECTION ON TABLE <TABLE_NAME>
K) SQL> SHOW PROTECTION ON DATABASE RDB$DBHANDLE;
L) SQL> SHOW TRIGGERS
M) SQL> SHOW TRIGGER <TRIGGER_NAME>
N) SQL>SHOW TABLE(TRIGGER) <TABLE_NAME>
O) SQL>SHOW SEQUENCE
Questions and Answers
To view full details, sign in with your My Oracle Support account. |
|
Don't have a My Oracle Support account? Click to get started! |
In this Document
Purpose |
Questions and Answers |