0

I'm trying to find the oracle error's description in SQL*PLUS. Similar command in DB2 as

? SQLXXXX

Where XXXX is the error number.

atokpas
8,6901 gold badge18 silver badges27 bronze badges
asked Feb 3, 2017 at 5:49
1

3 Answers 3

2

You can use oerr utility.

Example:

[oracle@ora12c Desktop]$ oerr ora 01950
01950, 00000, "no privileges on tablespace '%s'"
Cause: User does not have privileges to allocate an extent in the
 specified tablespace.
Action: Grant the user the appropriate system privileges or grant the user
 space resource on the tablespace.

You can search error code on this webpage Search for Error Messages or you can download the Database Error Messages documentation from here.

Note: This utility is not available on Windows.

answered Feb 3, 2017 at 6:00
1
  • Thanks for the reply. But i'm using Windows OS.So there is no utility for it? Commented Feb 3, 2017 at 8:18
0

You can prepend an exclamation mark ! in SQL*Plus to any shell command which will allow you to execute the command without leaving SQL*Plus:

Connected to:
Oracle Database 11g Release 11.2.0.3.0 - 64bit Production
SQL> !oerr ora 01950
01950, 00000, "no privileges on tablespace '%s'"
// *Cause: User does not have privileges to allocate an extent in the
// specified tablespace.
// *Action: Grant the user the appropriate system privileges or grant the user
// space resource on the tablespace.
SQL>
answered Feb 3, 2017 at 6:39
0

Well, for Windows, i can only remember calling the the SQLERRM function. Something like this: BEGIN DBMS_OUTPUT.PUT_LINE('SQLERRM(-6511): ' || TO_CHAR(SQLERRM(-6511))); END;

answered Feb 3, 2017 at 9:44

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

By clicking "Post Your Answer", you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.