Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.server -> Re: Create table in if-statement
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>...Received on Fri Jul 14 2000 - 00:00:00 CDT
>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.
![]() |
![]() |