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
How to find out what oracle odbc drivers are installed?
What is an oracle cursor variable?
How do I escape a reserved word in oracle?
Hi Can any one tell me what are the API's used in requisition import.
What is the difference between translate and replace?
How to bring a tablespace online?
what are bitmap indexes? How does they work?
How translate command is different from replace?
How to store only time; not date and time?
Explain an index?
What is a parameter file in oracle?
what is difference between sql plus and sql*plus? (not sql and sql plus).
What is the difference between substr & instr functions?
What is meant by an index?
How to write a left outer join with the where clause in oracle?