SELECT Multiple Rows of a Table INTO a PL/Sql TableRecord Without Using Cursor

From: Adam Tadjkarimi <adamt_at_hsltd.com>
Date: Thu, 22 Jul 1999 13:40:28 -0500
Message-ID: <7n7ojc$lmf$1_at_newsin-1.starnet.net>



[Quoted] [Quoted] I wonder if it is possible to SELECT directly multiple rows of a table into [Quoted] a PL/Sql table record without using cursor? Here is a simple example:

DECLARE
[Quoted]   TYPE PeriodRecTabType IS TABLE OF Period%ROWTYPE     INDEX BY BINARY_INTEGER;
  PeriodRecTab PeriodRecTabType;
  IndexVar BINARY_INTEGER := 1;
BEGIN
  SELECT * INTO PeriodRecTab(IndexVar)
    FROM Period;
  EXCEPTION
......
......

END; When I run it I get the ORA-01422, exact fetch returns more than requested number of rows.

Is it possible at all? any workaround?

Thanks,
Adam Tadj Received on Thu Jul 22 1999 - 20:40:28 CEST

Original text of this message