PL/SQL Collections and Records
Many programming techniques use collection types such as arrays, bags, lists, nested tables, sets, and trees.
To support collection techniques in database applications, PL/SQL provides the data types TABLE and VARRAY. These types enable you to declare associative arrays, nested tables, and variable-size arrays.
Collections
A PL/SQL collection is an ordered group of elements, all of the same type.
Each element has a unique subscript that determines its position in the collection. To create a collection, you first define a collection type, and then declare a variable of that type.
Collections work like the arrays found in most third-generation programming languages. Also, collections can be passed as parameters. So, you can use them to move columns of data into and out of database tables or between client-side applications and stored subprograms.
Comments
Post a Comment