Home » Developer & Programmer » Forms » how to use Cursor for loop ? (oracle forms 10g,11.1.7.0)
how to use Cursor for loop ? [message #629811] Tue, 16 December 2014 04:29 Go to next message
mist598
Messages: 1195
Registered: February 2013
Location: Hyderabad
Senior Member
Hi all,
A B
-- --
1 (1+2+3+4)-1=9
2 (2+3+4)-2=7
3 (3+4)-3=4
4 (4-4)=0


Per my example, I should sum(A) that > current value
to obtain value of B
IF A=1, then only (2,3,4) > 1, so I will SUM(2,3,4) to get 9
IF A=2 then only (3,4) > 2, so I will SUM(3,4) to get 7

Using cursor for Loop , so how to implement this in Oracle forms

Thanks in advanced,I don't want to hard code of A values(from in the above code) If a=1 then..bcz we don't know what values are in the A column's

[Updated on: Tue, 16 December 2014 04:31]

Report message to a moderator

Re: how to use Cursor for loop ? [message #629843 is a reply to message #629811] Tue, 16 December 2014 08:29 Go to previous messageGo to next message
CraigB
Messages: 386
Registered: August 2014
Location: Utah, USA
Senior Member
What have you tried? The purpose of the Forum is to HELP you write your code...not write it for you. Smile
Re: how to use Cursor for loop ? [message #629846 is a reply to message #629843] Tue, 16 December 2014 08:43 Go to previous message
cookiemonster
Messages: 13917
Registered: September 2008
Location: Rainy Manchester
Senior Member
You can do it with the analytic version of sum, no loops required.
Previous Topic: Result of one column will input to next column
Next Topic: installing form builder on windows 7
Goto Forum:
  


Current Time: Fri Mar 29 05:06:30 CDT 2024