|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
Stop making mediocre tutorials.The best tutorials are video! Camtasia Studio makes it easy to create engaging, buzz-building screen videos at any size, in any popular format. Download the free trial!
|
|
#1
|
|||
|
|||
|
Ref Cursor
Hi, I have written this code,,
create or replace package kit_admin as TYPE PackRec IS RECORD (pack_cd VARCHAR2(5)); TYPE crsr IS REF CURSOR RETURN PackRec; procedure selectPackages(V_crsr OUT crsr); end kit_admin; This package gets created nicely but the body is not getting created,,,, Body is as follows. create or replace package body kit_admin is TYPE crsr IS REF CURSOR RETURN PackRec; procedure selectPackages(V_crsr OUT crsr) is V_crsr is select package_cd from kit_packages; end selectPackages; end kit_admin; the error while creating this body is as follows: Errors for PACKAGE BODY KIT_ADMIN: LINE/COL ERROR -------- ----------------------------------------------------------------- 6/10 PLS-00103: Encountered the symbol "SELECT" when expecting one of the following: constant exception <an identifier> <a double-quoted delimited-identifier> table LONG_ double ref char time timestamp interval date binary national character nchar 9/2 PLS-00103: Encountered the symbol "END" when expecting one of the following: begin function package pragma procedure subtype type use <an identifier> <a double-quoted delimited-identifier> cursor LINE/COL ERROR -------- ----------------------------------------------------------------- form current Please suggest,, Thanks |
|
#2
|
|||
|
|||
|
Re: Ref Cursor
What exactly are you trying to do here?
|
|
#3
|
|||
|
|||
|
It seems like you're approaching your task with more complicated pl/sql than is necessary...
As martysb asked, what are you trying to accomplish here? |
![]() |
| Viewing: Dev Shed Forums > Databases > Oracle Development > Ref Cursor |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|
|