anthas.blogg.se

Cursors set
Cursors set







  1. Cursors set update#
  2. Cursors set code#

Cursors set update#

You cannot update the database by using a REF CURSOR.Ī REF CURSOR is not backward scrollable. The result set represented by the REF CURSOR is read-only. Note that data is not be retrieved until the user attempts to read it.Ī REF CURSOR is not updatable. While the REF CURSOR is returned to the client, the actual data is not returned until the client opens the REF CURSOR and requests the data. Therefore, the client must be connected to the database during the lifetime of the REF CURSOR in order to access it.Ī REF CURSOR involves an additional database round-trip. REF CURSORs have the following characteristics:Ī REF CURSOR refers to a memory address on the database. REF CURSORs are represented through the OracleRefCursor ODP.NET class. In essence, a REF CURSOR is a pointer or a handle to a result set on the database. Using REF CURSORs is one of the most powerful, flexible, and scalable ways to return query results from an Oracle Database to a client application.Ī REF CURSOR is a PL/SQL data type whose value is the memory address of a query work area on the database. While it is possible to have a specification without a body, as when declaring a set of public constants, it is not possible to have a body with no specification. The specification is stored as the PACKAGE type, and the body is stored as the PACKAGE BODY type. The package specification and body are stored as separate objects in the data dictionary and can be seen in the user_source view.

Cursors set code#

This private code is only visible within the package body. The package body contains the code for the procedures and functions defined in the specification, and the code for private procedures and functions that are not declared in the specification. The specification is the published interface to a package. The specification defines all public items. The package specification defines what is contained in the package it is analogous to a header file in a language such as C++. A package is composed of two distinct pieces:

cursors set cursors set

Introduction to PL/SQL Packages and Package BodiesĪ PL/SQL package stores related items as a single logical entity.









Cursors set