Home » SQL & PL/SQL » SQL & PL/SQL » diffDiffereence when we use INDEX BY BINARY_INTEGER in TypePE (oracle 9.2.0.3)
diffDiffereence when we use INDEX BY BINARY_INTEGER in TypePE [message #404591] Fri, 22 May 2009 07:14 Go to next message
prachij593
Messages: 266
Registered: May 2009
Senior Member
TYPE IS TABLE OF NUMBER;

TYPE IS TABLE OF NUMBER INDEX BY BINARY INTEGER


What is the difference between the two when we use inside pl/sql block? what happends when we use INDEX BY BINARY INTEGER
Re: diffDiffereence when we use INDEX BY BINARY_INTEGER in TypePE [message #404594 is a reply to message #404591] Fri, 22 May 2009 07:20 Go to previous messageGo to next message
bonker
Messages: 402
Registered: July 2005
Senior Member
In first case you have need to mandatorily initialize and extend to assign values in the collection unless you are using bulk collect. For second case you need not initialize or extend to assign values in the collection.

Additionally read this link for further understanding

http://asktom.oracle.com/pls/asktom/f?p=100:11:0::::P11_QUESTION_ID:3170352229012
HTH


[Edit- Added Asktom URL]

[Updated on: Fri, 22 May 2009 07:22]

Report message to a moderator

Re: diffDiffereence when we use INDEX BY BINARY_INTEGER in TypePE [message #404604 is a reply to message #404594] Fri, 22 May 2009 07:46 Go to previous messageGo to next message
prachij593
Messages: 266
Registered: May 2009
Senior Member
Thank you Sir for such a nice link.
Re: diffDiffereence when we use INDEX BY BINARY_INTEGER in TypePE [message #404610 is a reply to message #404594] Fri, 22 May 2009 07:58 Go to previous messageGo to next message
JRowbottom
Messages: 5933
Registered: June 2006
Location: Sunny North Yorkshire, ho...
Senior Member
Additionally, the first type can be declared in SQL, allowing you to reference user-defined collections from SQL as well as pl/sql
Re: diffDiffereence when we use INDEX BY BINARY_INTEGER in TypePE [message #404650 is a reply to message #404610] Fri, 22 May 2009 11:17 Go to previous message
prachij593
Messages: 266
Registered: May 2009
Senior Member
Sir, thank you very much!
Previous Topic: Date comparison using DECODE
Next Topic: WebServices
Goto Forum:
  


Current Time: Mon Dec 05 18:50:47 CST 2016

Total time taken to generate the page: 0.08119 seconds