Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

Hi,
I want table structure shown below. How can i create this ?
Num Name Address
Addr1 Addr2


I want Addr1 and Addr2 under Address column.
How can i achive this ? Is it possible ?

Answer Posted / begum

hi this is really work

create type addr as object (
add1 varchar2(15),
add2 varchar2(15));
/
create table nest1 (
id number(2),
name varchar2(10),
address addr);

insert into nest1 values(10,'uma',addr('10th
main','bangalore'));
/
insert into nest1 values(20,'sami',addr('77g
colony','chennai'));

SQL> select * from nest1;

ID NAME
---------- ----------
ADDRESS(ADD1, ADD2)
--------------------------------------------
10 uma
ADDR('10th main', 'bangalore')

20 sami
ADDR('77g colony', 'chennai')

Is This Answer Correct ?    12 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Difference between cartesian join and cross join?

1058


What is the cache hit ratio, what impact does it have on performance of an Oracle database and what is involved in tuning it?

2141


What is the difference between 10g OEM and 11g OEM?

974


Please send me Informatica 8.1 certification dumps, my mail id mona85gupta@gmail.com

1870


Differentiate between pre-select and pre-query?

1118


How a tablespace is related to data files?

1114


How to increment dates by 1 in oracle?

1104


Is there a combination of "like" and "in" in sql?

1076


how to do daily transactions with out sql* loader control file regesterd in apps?

1693


what is the dual table in oracle?

1005


how to make an oracle object

2367


How to assign data of the deleted row to variables?

1083


How to run create database statement?

1043


When system tablespace is created?

1049


How to rename an existing table?

1136