SQL*Plus User's Guide and Reference Release 8.1.6 A75664-01 |
|
Command Reference, 41 of 52
Shows the value of a SQL*Plus system variable or the current SQL*Plus environment.
SHO[W] option
where option represents one of the following terms or clauses:
system_variable ALL BTI[TLE] ERR[ORS] [{FUNCTION|PROCEDURE|PACKAGE|PACKAGE BODY| TRIGGER|VIEW|TYPE|TYPE BODY} [schema.]name] LNO PARAMETERS [parameter_name] PNO REL[EASE] REPF[OOTER] REPH[EADER] SGA SPOO[L] SQLCODE TTI[TLE] USER
Refer to the following list for a description of each term or clause:
system_variable
ALL
BTI[TLE]
ERR[ORS] [{FUNCTION|PROCEDURE|PACKAGE|PACKAGE BODY
|TRIGGER|VIEW|TYPE|TYPE BODY} [
schema
.]
name
]
Shows the compilation errors of a stored procedure (includes stored functions, procedures, and packages). After you use the CREATE command to create a stored procedure, a message is displayed if the stored procedure has any compilation errors. To see the errors, you use SHOW ERRORS.
When you specify SHOW ERRORS with no arguments, SQL*Plus shows compilation errors for the most recently created or altered stored procedure. When you specify the type (function, procedure, package, package body, trigger, view, type, or type body) and the name of the PL/SQL stored procedure, SQL*Plus shows errors for that stored procedure. For more information on compilation errors, see your PL/SQL User's Guide and Reference.
schema contains the named object. If you omit schema, SHOW ERRORS assumes the object is located in your current schema.
SHOW ERRORS output displays the line and column number of the error (LINE/COL) as well as the error itself (ERROR). LINE/COL and ERROR have default widths of 8 and 65, respectively. You can alter these widths using the COLUMN command.
LNO
PARAMETERS [
parameter_name
]
SQL> SHOW PARAMETERS COUNT
you would see:
NAME TYPE VALUE ------------------------------ ----- ----- db_file_multiblock_read_count integer 12 spin_count integer 0
The SHOW PARAMETERS command, without any string following the command, displays all initialization parameters.
Note, your output may vary depending on the version and configuration of the Oracle database server to which you are connected. You need SELECT ON V_$PARAMETER object privileges to use the PARAMETERS clause, otherwise you will receive a message
ORA-00942: table or view does not exist
PNO
REL[EASE]
REPF[OOTER]
REPH[EADER]
SPOO[L]
SGA
ORA-00942: table or view does not exist
SQLCODE
TTI[TLE]
USER
To list the current LINESIZE, enter
SQL> SHOW LINESIZE
If the current linesize equals 80 characters, SQL*Plus will give the following response:
linesize 80
The following example illustrates how to create a stored procedure and then show its compilation errors:
SQL> connect system/manager SQL> create procedure scott.proc1 as SQL> begin SQL> :p1 := 1; SQL> end; SQL> / Warning: Procedure created with compilation errors. SQL> show errors Errors for PROCEDURE SCOTT.PROC1: LINE/COL ERROR -------------------------------------------------------- 3/3 PLS-00049: bad bind variable 'P1' SQL> show errors procedure proc1 No errors. SQL> show errors procedure scott.proc1 Errors for PROCEDURE SCOTT.PROC1: LINE/COL ERROR -------------------------------------------------------- 3/3 PLS-00049: bad bind variable 'P1'
To show whether AUTORECOVERY is enabled, enter
SQL> SHOW AUTORECOVERY autorecovery ON
To display the connect string for the default instance, enter
SQL> SHOW INSTANCE instance "local"
To display the location for archive logs, enter
SQL> SHOW LOGSOURCE logsource "/usr/oracle81/dbs/arch"
To display information about the SGA, enter
SQL> SHOW SGA Total System Global Area 7629732 bytes Fixed Size 60324 bytes Variable Size 6627328 bytes Database Buffers 409600 bytes Redo Buffers 532480 bytes
|
![]() Copyright © 1999 Oracle Corporation. All Rights Reserved. |
|