Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: SELECT FROM PACKAGE

Re: SELECT FROM PACKAGE

From: Sybrand Bakker <gooiditweg_at_sybrandb.demon.nl>
Date: Sun, 03 Aug 2003 22:39:19 +0200
Message-ID: <sjsqivomgrmjtk9gmt5n900hnop4tqeu0k@4ax.com>


On 3 Aug 2003 12:29:55 -0700, mmontreaux_at_hotmail.com (Monty) wrote:

>Hi, we are using a commercial piece of software that has all user
>error messages stored in an Oracle package. I am wanting to customize
>a bit of software and use the same messages (two packages, one in
>English and the other in Frence) but cannot find out how to retrieve
>the text from them. Here is an example:
>
>CREATE OR REPLACE PACKAGE errMessages IS
>err1 CONSTANT VARCHAR2(100) := 'Illegal error due to...';
>err2 VARCHAR2(100) := 'Invalid number in customer id...';
>err3 VARCHAR2(100) := 'PLease reenter details for customer id';
>END errMessages;
>/
>
>I want the select to return all the VARCHAR2 so I can see what they
>all are. But when I execute the below I get an error.
>
>SQL>
>SQL> SELECT errMessages.err1,errMessages.err2,errMessages.err3 FROM
>DUAL;
>SELECT errMessages.err1,errMessages.err2,errMessages.err3 FROM DUAL
> *
>ERROR at line 1:
>ORA-06553: PLS-221: 'ERR3' is not a procedure or is undefined
>
>SQL>
>SQL>
>SQL>
>
>I understand the error and what is wrong but still want to see the
>text in an SQL box. Can someone help please. Using Oracle 9 on a Win2K
>server.
>Thank you
>Monty

In this form: just forget about it. They are not stored in an array, you cannot return them by calling a function in the package, they are not stored in a table.
Clear example of lousy programming of the vendor.

Sybrand Bakker, Senior Oracle DBA

To reply remove -verwijderdit from my e-mail address Received on Sun Aug 03 2003 - 15:39:19 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US