Home » Other » Training & Certification » confused please
confused please [message #316890] Mon, 28 April 2008 15:25 Go to next message
aatishpatel
Messages: 4
Registered: March 2008
Junior Member

-- An object type has changed its definition. what should you do to a table containing a column with the changed object type?

--Is the command valid or not? why
ALTER TABLE CAR
DROP COLUMMN CAR_OWNER
RENAME COLUMN CAR_MANUFACTURER TO CAR_MANUF;



please reply asap. your help is appreciated
Re: confused please [message #316892 is a reply to message #316890] Mon, 28 April 2008 16:08 Go to previous messageGo to next message
pablolee
Messages: 2658
Registered: May 2007
Location: Scotland
Senior Member
Just checked this poster's history. Complete waste of space.

[Updated on: Mon, 28 April 2008 16:09]

Report message to a moderator

Re: confused please [message #316894 is a reply to message #316892] Mon, 28 April 2008 16:46 Go to previous message
S.Rajaram
Messages: 1027
Registered: October 2006
Location: United Kingdom
Senior Member
I am not sure whether this is a sheer coincidence. You were the first person to reply to all of his previous postings. Smile

To OP :
SQL> create table car (car_owner varchar2(15), car_manufacturer varchar2(15));

Table created.

SQL>  ALTER TABLE CAR
  2  DROP COLUMMN CAR_OWNER
  3  RENAME COLUMN CAR_MANUFACTURER TO CAR_MANUF;
DROP COLUMMN CAR_OWNER
     *
ERROR at line 2:
ORA-00905: missing keyword


SQL> ed
Wrote file afiedt.buf

  1   ALTER TABLE CAR
  2  DROP COLUMMN CAR_OWNER
  3* RENAME COLUMN CAR_MANUFACTURER TO CAR_MANUFactuer
SQL> /
DROP COLUMMN CAR_OWNER
     *
ERROR at line 2:
ORA-00905: missing keyword


SQL> ed
Wrote file afiedt.buf

  1   ALTER TABLE CAR
  2  DROP COLUMN CAR_OWNER
  3* RENAME COLUMN CAR_MANUFACTURER TO CAR_MANUFactuer
SQL> /
RENAME COLUMN CAR_MANUFACTURER TO CAR_MANUFactuer
*
ERROR at line 3:
ORA-00933: SQL command not properly ended


Regards

Raj

[Updated on: Mon, 28 April 2008 16:50]

Report message to a moderator

Previous Topic: trigger question
Next Topic: Develop PL/SQL Program Units
Goto Forum:
  


Current Time: Fri Dec 19 20:45:51 CST 2014

Total time taken to generate the page: 0.09744 seconds