Home » SQL & PL/SQL » SQL & PL/SQL » Please provide real time scenario for when we use object type in PL/SQL block (Oracle 11g)
Please provide real time scenario for when we use object type in PL/SQL block [message #584624] Thu, 16 May 2013 06:59 Go to next message
ajaykumarkona
Messages: 399
Registered: August 2010
Senior Member
Hi Experts,

When we use this kind of code in PL/SQL block.

CREATE OR REPLACE TYPE sample_object IS OBJECT
(id       NUMBER
,name     VARCHAR2(30));
/
 
CREATE OR REPLACE TYPE sample_table IS TABLE OF sample_object;


I have read some docs ,but I didn't get any information where exactly we use this.

Please provide one real time scenario with an example.

How this is different from record.

Thanks in advance.
Re: Please provide real time scenario for when we use object type in PL/SQL block [message #584626 is a reply to message #584624] Thu, 16 May 2013 07:03 Go to previous message
Michel Cadot
Messages: 58860
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
DDL must be done via EXECUTE IMMEDIATE (please refer to the documentation).

"Please provide one real time scenario" -> there is NO real time scenario you have to use this (unless you develop an application generator).

Regards
Michel
Previous Topic: Want to display the data from two tables in SQL
Next Topic: DBLINK, DBMS_AQADM, STOP/START QUEUE
Goto Forum:
  


Current Time: Fri Aug 22 03:19:55 CDT 2014

Total time taken to generate the page: 0.11068 seconds