Cursor is a pointer to a memory area called context area. This we have already learnt with all the other details in the previous tutorial. Today in this blog we will learn how to create an explicit database cursor.
As we have already learnt that whenever we execute a DML statement, the oracle server creates an implicit cursor in the background. As these cursors are created by oracle server itself thus user does not have much programmatic control on them. In case if you want to control your own DMLs then you need to write an explicit cursor.
So let’s quickly see how you can create your own database cursor in oracle database.
Declaration of your cursor can only be done in the “Declaration” section of the PL/SQL block and the rest of the steps of explicit cursor creation cycle must be done in the execution section of a PL/SQL block.
This is a quick tutorial on how to create an explicit cursor in oracle database. Hope you liked it. Do make sure to share this blog on your Facebook or click here to share it on your twitter quickly. Thanks for reading & have a great day!
You can DOWNLOAD SQL script and presentation used in the Video and in this article.