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: Create table in if-statement

Re: Create table in if-statement

From: Eugenio <eugenio.spadafora_nospam_at_compaq.com>
Date: 2000/07/14
Message-ID: <8kmres$r5f$1@mailint03.im.hou.compaq.com>#1/1

I think you cannot use DDL inside a PL/SQL block. You shoul use DBMS_SQL package or the way posted by Kathinka .

--
Ciao

Eugenio
remove _nospam from reply address

Opinions are mine and do not necessarily reflect those of my company

=======================================================
poluha_at_my-deja.com wrote in message <8kmnrj$2ae$1_at_nnrp1.deja.com>...

>In article <8kmj2k$2p9o4$1_at_ID-6887.news.cis.dfn.de>,
> "Kathinka Diehl" <kathinka_at_rrr.de> wrote:
>>
>> <poluha_at_my-deja.com> schrieb:
>> >
>> > What I want to do is to check whether a table already exists. If it
>> > doesn't I want to create it, otherwise I want to empty it.
>>
>> Why you don't do it in this way: just drop it first if it exists or
not and
>> then create a new one?
>>
>> Regards,
>> Kathinka
>>
>
>Thanks for your quick response.
>
>I can't drop a table that doesn't exist. If I try I get "Table or view
>doesn't exist."
>
>Regards,
>P Poluha
>
>
>Sent via Deja.com http://www.deja.com/
>Before you buy.
Received on Fri Jul 14 2000 - 00:00:00 CDT

Original text of this message

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