cursor problem

From: Srikanth Patibanda <spatiba2_at_cs.uno.edu>
Date: 1997/02/07
Message-ID: <32FBB1D8.41E4_at_cs.uno.edu>#1/1


Hello,

        I have some problems regarding the cursors.

actually i want to get more than one row from the database. so i am using the cursors to get it. but unfortunately i am not able to get the records. Yesterday i have given this email and i got one answer that i should use NEXT_RECORD in the loop. Even after using that i am able to get the records but its not showing all at a time.

        Actually my problem is i want to get the records and to display all on
the screen at a time. As a normal query operates.

The code i used is GIVEN BELOW

NOTE: I WANT TO DISPLAY ALL THE RECORDS AT A TIME ON THE SCREEN. DECLARE
cursor c1 is

        select st_id, sample_date, time, compid, concentration
         from analyzed_samples1
        where st_id = :segments.st_id and  
        (sample_date between :segments.firstdate and :segments.lastate);
        
        
         

BEGIN  

        open c1;
        loop
         
                fetch  c1 into :analyzed_samples3.st_id, 

:analyzed_samples3.sample_date,
:analyzed_samples3.time,
:analyzed_samples3.compid,
:analyzed_samples3.concentration;
exit when c1%notfound; next_record; end loop; close c1;

END;  I really appreciate if anyone answer my question.

Thanking you

SRIKANTH.PATIBANDA Received on Fri Feb 07 1997 - 00:00:00 CET

Original text of this message