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

Home -> Community -> Usenet -> c.d.o.tools -> Re: Create View from within Stored Procedure?

Re: Create View from within Stored Procedure?

From: Akram JARO <akram_jaro_at_yahoo.com>
Date: Wed, 18 Oct 2000 17:28:44 GMT
Message-ID: <g5lH5.12047$AV6.583293@news.chello.at>

hi

it's not possible to use DDL in stored procedures :(((

ciao
@kram JARO
Vienna - Austria
David L. Hoffman <davidh_at_abacus96.com> schrieb in im Newsbeitrag: hYkH5.31$BE5.770_at_client...
> Hi, sorry if this is the world's dumbest question:
>
> Is it possible to create a stored procedure which creates a view?
>
> It seems not, based on the results shown below (using Oracle 7.3). Or am
 I
> just missing something?
>
> Many thanks-
> -David Hoffman
> -------------------------------------------------------------
> SQL> create or replace procedure TESTY
> 2 AS BEGIN
> 3 CREATE VIEW TESTVIEW AS
> 4 SELECT * FROM BROKER;
> 5 END;
> 6 /
>
> Warning: Procedure created with compilation errors.
>
> SQL>
> SQL>
> SQL>
> SQL> show errors
> Errors for PROCEDURE TESTY:
>
> LINE/COL ERROR
> -------- -----------------------------------------------------------------
> 3/3 PLS-00103: Encountered the symbol "CREATE" when expecting one of
> the following:
> begin declare exit for goto if loop mod null pragma raise
> return select update while <an identifier>
> <a double-quoted delimited-identifier> <a bind variable>
> <a single-quoted SQL string> << close delete fetch lock
> insert open rollback savepoint set sql commit
>
>
>
Received on Wed Oct 18 2000 - 12:28:44 CDT

Original text of this message

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