Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> Re: Creating types in Orace 9i: why it doesn't work?
Well, best to read a bit b4 testing it. Look up SQL reference manual
on how to create a user_defined datatype. A simple example would be
like,
create or replace type as object (.....);
and then you can
create table <name> of <the type you created>;
"Roman Zhovtulya" <roman_at_fh-offenburg.de> wrote in message news:<arli5s$grf$1_at_news.BelWue.DE>...
> Hello,
> Just wondering if anyone had the problem creating types in Oracle 9i (I'm
> trying to explore object-oriented features of Oracle).
> The strange thing is that it goesn't give any error when I execute the
> following (I've tried both Toad and SQLPlus):
>
> create type Persontype
> (
> PersNr integer,
> Name varchar(30),
> primary key (EmpNr)
> );
>
> , but it gives "invalid datatype" error when I execute the following:
>
> create table Student of persontype;
>
> Any help would be appreciated.
>
> Thanks a lot,
> Roman Zhovtulya
>
> Database Lab
>
> -------------------------------------------------------
> M.Sc. Roman Zhovtulya
> Research Assistant
> Database Lab
> Offenburg University of Applied Sciences
>
> roman_at_fh-offenburg.de
> -------------------------------------------------------
Received on Fri Nov 22 2002 - 13:40:57 CST
![]() |
![]() |