We have used them time and again but never got the chance to talk about them. Thus today we will discuss collection methods.
What are Collection Methods?
Collection methods are PL/SQL’s in-built functions and procedures which can be used in conjunction with collections.
So, what they can do for you?
Using PL/SQL collection method you can get the information as well as alter the content of the collection.
How many collection methods do we have?
In Oracle Database we have 3 Collection Procedures and 7 Collection functions. In total we have 10 collection methods. Here are their names —
- First, Last
- Prior, Next
Since the syntax for using the collection built-ins is different from the normal syntax used to call procedures and functions therefore they are referred to as methods.
How do we use collection methods?
In Oracle PL/SQL, collection methods can be used using Dot (.) notation. Let’s take a look at the syntax.
Collection. Method (parameters)
That is the quick introduction to collection methods in Oracle Database. In the upcoming videos we will explore in detail each of the above mentioned methods individually.
Thanks and have a nice day!
[…] mentioned in the previous tutorial that there are 7 collection functions. Among these seven collection function – COUNT ( ) is the […]
[…] we saw in the Introduction to PL/SQL Collection Methods that there are 7 collection functions in Oracle Database. Among these seven functions we have […]
[…] discussed in the Introduction to collection methods we have seven collection functions and 3 collection procedures. Therefore in total we have 10 […]