The Oracle (tm) Users' Co-Operative FAQ

Is there a Windows version of the oerr program?

Author's name: Yong Huang

Author's Email:

Date written: 18th June 2001
Updated: 3rd November 2004

Oracle version(s): 8i to 10g

In UNIX, you type oerr ora 1234 to get a description and suggested action about the Oracle error 1234. Oracle does not provide this utility in Windows. What can you do?

Back to index of questions

The UNIX version oerr program is a shell script that reads the text files $ORACLE_HOME/*/mesg/*.msg, most notably $ORACLE_HOME/rdbms/oraus.msg. But the Windows version Oracle does not bundle this utility and does not have human-readable error message files; it only has the binary versions such as %ORACLE_HOME%\RDBMS\mesg\oraus.msb and its format is not published by Oracle. So you can't build your own program based on that. The following are alternatives in order of relevance to the question.

1. Yong Huang wrote a freeware Perl script Windows oerr that reads the Oracle documentation Error Message pages and returns the error description and suggested action. It generally requires installing Perl and Oracle documentation locally. Minimum installation requires the Error Message part of documentation and compiled version of the Perl script (so you don't need the Perl interpreter).

2. Several people made attempts to build oerr based on the UNIX message files. The only one we still have access to is Bill Pollack's ora-text at his site. It requires you to ftp oraus.msg under rdbms from UNIX to PC.

3. Inside SQL*Plus or PL/SQL, you can use the sqlerrm function. For example, in SQL*PLus, set serveroutput on. Then exec dbms_output.put_line(sqlerrm(-1555)). This does not need any extra installation but gives you very limited error description and only works for the ORA facility, of course the largest facility in Oracle.

4. William Rogge posted a message to an Oracle mailing list publishing an awk script that parses $ORACLE_HOME/rdbms/mesg/oraus.msg and loads its content into an Oracle table. Obviously this requires client access to the database server to get the error description. I can't find the author or his script any more.

Note that not all error descriptions are exactly the same between UNIX $ORACLE_HOME/rdbms/mesg/oraus.msg and the Error Message page of documentation. Try oerr pls 123 at the UNIX prompt and then look it up in documentation.

Further Reading: none

Back to top

Back to index of questions