Apakah yang dimaksud seperti contoh berikut ini?

create table mytable (fielda varchar2(5), fieldb varchar2(5));

create procedure loopmytable is
cursor c1 is
  select fielda, fieldb from mytable;
r1       c1%rowtype;
a mytable.fielda%type;
b mytable.fieldb%type;
begin
  open c1;
  loop
    fetch c1 into r1;
    exit when c1%notfound;
    a:= r1.fielda;
    b:= r1.fieldb;
  end loop;
  close c1;
end;

Semoga membantu.


Salam,

Indra Armansyah.
[EMAIL PROTECTED]


  ----- Original Message ----- 
  From: Asep Inbisco IT 
  To: [email protected] 
  Sent: Wednesday, March 21, 2007 8:19 AM
  Subject: [indo-oracle] Looping Didalam Table


  Teman-teman masih ada yang ingat syntax looping dbase atau foxpro, yang mana
  looping tersebut berputar dari awal record sampai dengan akhir record dalam
  table (EOF).

  Do While Not EOF()

  A=FieldA

  B=FieldB

  Skip

  Enddo

  Dari contoh diatas kita melihat isi kolom dalam table (field) langsung bisa
  dimasukan ke variable memory, bisakah hal tersebut dijalankan juga di
  PL/SQL? 

  Kalau memang bisa tolong beri contoh saya, soalnya saya lagi dapat tugas nih
  yang mirip dengan contoh di atas.Terimakasih.

  [Non-text portions of this message have been removed]



   


------------------------------------------------------------------------------


  No virus found in this incoming message.
  Checked by AVG Free Edition.
  Version: 7.5.446 / Virus Database: 268.18.14/727 - Release Date: 3/19/2007 
11:49 AM


[Non-text portions of this message have been removed]

Kirim email ke