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 -> object, invalid column name, Weird!

object, invalid column name, Weird!

From: <liux99_at_my-deja.com>
Date: Thu, 10 Feb 2000 17:53:34 GMT
Message-ID: <87utus$kh6$1@nnrp1.deja.com>


I created type address_ty, person_ty like this (all the examples are from George Koch's book ORacle 8: the complete Reference) create type address_ty as object
(Street varchar2(50),

 city varchar2(25),
 State Char(2),
 Zip NUMBER);

create type person_ty as object
(Name varchar2(25),

 Address Address_ty);

then I created a table customer
create table customer
(Customer_ID NUMBER,

 Person Person_TY);

then I inserted a row into the table
insert into customer values
(1, person_ty('Neil Mullane', Address_ty('57 MT ST', 'FINN', 'NH',
1234)));

then I select * from customer, the data is there. all the above statement are successful.

But when I select the object's attribute, I always got invalid column name. Like this statement:
  select Person.Name from Customer;
  select Person.Address.Street from customer; Why these so straightforward statement won't work? Anybody got any idea?

Sent via Deja.com http://www.deja.com/
Before you buy. Received on Thu Feb 10 2000 - 11:53:34 CST

Original text of this message

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