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: alter view???

Re: alter view???

From: Shawn Ellinger <sellinge_at_csac.com>
Date: Wed, 27 Sep 2000 21:51:54 GMT
Message-ID: <39D26AFA.9CAEB2EB@csac.com>

Sounds like you are trying update a table column within a view. Oracle will not let you do that. You can only chage the underlying table. Then this will filter thru to the view.

Also, you are trying to change the column type of wk_end. Cant do that in a table either. You will have to basically drop the column and add it back in.

An easy way to do this is to:

  1. rename the table using RENAME TABLE command.
  2. create the new table using CREATE TABLE AS SELECT command. B.1) in this command use a To_DATE fuction for changing the WK_END column.
  3. Since you used the RENAME TABLE command all foreign keys are still pointing to the renamed table. You will have to locate those and redo them.

This process is easy just time consuming.

hajir_at_my-deja.com wrote:
>
> does this work?
>
> ALTER VIEW HAJIR4 MODIFY WK_END (DATE)
>
> ERROR at line 1:
> ORA-00922: missing or invalid option
>
> currently in view HAJIR4, WK_END is in VARCHAR format.
>
> Sent via Deja.com http://www.deja.com/
> Before you buy.
Received on Wed Sep 27 2000 - 16:51:54 CDT

Original text of this message

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