Dicas do Oracle Forms Builder - Blocos, Itens, LOV, Canvas, Triggers, comandos, PLL, d2kwutil, FMB, Alert, menus, etc
bessa_lucas
Rank: Programador Sênior
Posts: 55 Joined: Fri, 17 Oct 2014 3:02 pm
Lucas Bessa
Analista de Sistemas
lucas.bessa@obers.com.br
lucas.bessa.ti@gmail.com
Wed, 14 Oct 2015 4:18 pm
Gentlemen,
I have a very beginner doubt here, but in my company in almost all "whiles" are done so
Select all
while :system.last_record != 'TRUE' loop
SOME CODE
end loop
MORE CODE
The staff here uses
:system.last_record
to scroll through a list, but the last line is not executed. So we have to put the same loop code outside to run one more time.
Question:
Would it have any more practical form for him to perform everything within the loop?
bessa_lucas
Rank: Programador Sênior
Posts: 55 Joined: Fri, 17 Oct 2014 3:02 pm
Lucas Bessa
Analista de Sistemas
lucas.bessa@obers.com.br
lucas.bessa.ti@gmail.com
Thu, 15 Oct 2015 9:38 am
tiago_pimenta then I'll test and let you know if it worked!
Thanks!
tiago_pimenta
Rank: DBA Júnior
Posts: 213 Joined: Wed, 29 Jun 2011 9:49 am
Location: Barretos / SP
Thu, 15 Oct 2015 11:50 am
Bessa,
Only a correction, I forgot the NEXT_RECORD
So it would be like this:
Select all
loop
<código>
exit when :system.last_record = 'TRUE';
next_record;
end loop;
bessa_lucas
Rank: Programador Sênior
Posts: 55 Joined: Fri, 17 Oct 2014 3:02 pm
Lucas Bessa
Analista de Sistemas
lucas.bessa@obers.com.br
lucas.bessa.ti@gmail.com
Thu, 15 Oct 2015 4:14 pm
tiago_pimenta
Perfect! Tested and approved!
tiago_pimenta
Rank: DBA Júnior
Posts: 213 Joined: Wed, 29 Jun 2011 9:49 am
Location: Barretos / SP
Users browsing this forum: No registered users and 14 guests