Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: ORA-00999
"DA Morgan" <damorgan_at_psoug.org> wrote in message
news:1172255605.776958_at_bubbleator.drizzle.com...
> Just found something without a single reference at metalink or that I
> can find using google.
>
> Can anyone explain what is happening here?
>
> SQL> CREATE OR REPLACE PACKAGE test AS
> 2 FUNCTION myfunc( args ...) RETURN VARCHAR2;
> 3 END test;
> 4 /
>
> Package created.
>
> SQL> CREATE OR REPLACE FUNCTION myfunc(args ...) RETURN VARCHAR2 AS
> 2 BEGIN
> 3 RETURN 'A';
> 4 END;
> 5 /
>
> Warning: Function created with compilation errors.
>
> SQL> sho err
> Errors for FUNCTION DUMMY:
>
> LINE/COL ERROR
> -------- -----------------------------------------------------------------
> 1/16 PLS-00999: implementation restriction (may be temporary)
> ellipsis not allowed in this context
>
> SQL>
>
>
> What is the meaning of (args ...) as an input parameter?
>
> And lest you think it invalid syntax ... check out
> /rdbms/admin/utllms.sql
>
> I am trying to figure out what the UTL_LMS package header means.
>
> Thanks.
> --
> Daniel A. Morgan
> University of Washington
> damorgan_at_x.washington.edu
> (replace x with u to respond)
> Puget Sound Oracle Users Group
> www.psoug.org
Not sure if this is the be-all and end-all, but it allows a convenient pl/sql interface to formatting error messages:
SQL> l
1 declare
2 mv varchar2(4000);
3 begin
4 mv := utl_lms.format_message( 5 'unique constraint (%s.%s) violated', 6 'schema', 7 'constraint' 8 ); 9 dbms_output.put_line(mv);
It's possible that there is an event you can set to make the "..." legal.
Basically, it looks like the Oracle equivalent of printf(), viz: a function that isn't a proper function because is can have any number of input parameters.
-- Regards Jonathan Lewis http://jonathanlewis.wordpress.com Author: Cost Based Oracle: Fundamentals http://www.jlcomp.demon.co.uk/cbo_book/ind_book.html The Co-operative Oracle Users' FAQ http://www.jlcomp.demon.co.uk/faq/ind_faq.htmlReceived on Fri Feb 23 2007 - 12:58:58 CST