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: Help Renaming Tables!!!

Re: Help Renaming Tables!!!

From: Jonathan Gennick <jonathan_at_gennick.com>
Date: Tue, 15 Aug 2000 13:56:42 GMT
Message-ID: <4kiipssbruh8vf7rljap5tt3m8vr55rgcc@4ax.com>

For one thing, you cannot embed a SELECT within an ALTER TABLE statement. How are you trying to implement this process? Are you writing PL/SQL code on the server, or are you executing these statements from a client? If you're writing PL/SQL on the server, you'll need to use dynamic SQL (the DBMS_SQL package) to execute your ALTER TABLE statement.

Jonathan



jonathan_at_gennick.com
http://gennick.com
Brighten the Corner Where You Are

On Mon, 14 Aug 2000 15:32:14 -0500, "Tommy" <motykat_at_thriftycall.com> wrote:

>This is what I have tried and can not make it work:
>
>Alter Table
>(select 'OCC'|| (to_char(sysdate,'YYYYMMDD') - 15) || 'DAILY' into t from
>dual)
>Rename To
>(select 'OCC'|| (to_char(sysdate,'YYYYMMDD')) || 'DAILY' into t from dual);
>
>Can anyone tell me how to make this work?
Received on Tue Aug 15 2000 - 08:56:42 CDT

Original text of this message

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