Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> problem modify column constraint

problem modify column constraint

From: Richard Chen <richard_at_lexitech.com>
Date: Sat, 29 May 1999 08:14:37 -0400
Message-ID: <374FDA2C.D4B946DE@lexitech.com>


The docs says one can modify column constraint using alter. But the following does not work:

SQL> drop table phone_numbers;

Table dropped.

SQL> create table phone_numbers (

  2  email           varchar(100) not null references mailing_list,
  3  number_type     varchar(15) check (number_type in ('work','home')),

  4 phone_number varchar(20));

Table created.

SQL> alter table phone_numbers modify (number_type varchar(15) check
(number_type in ('work','home','cell')));

alter table phone_numbers modify (number_type varchar(15) check
(number_type in ('work','home','cell')))

                                                          *
ERROR at line 1:
ORA-02253: constraint specification not allowed here

Is there a syntax error or is it not possible to modify constraints like this?

Thanks for any info.

Richard Received on Sat May 29 1999 - 07:14:37 CDT

Original text of this message

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