Subject Re: [ib-support] cursors in sp??
Author Helen Borrie
At 05:20 PM 03-10-02 -0700, you wrote:
>Lucas,
>
>the sp that you gave me works well, but it only works for 1 record. what i
>need is a cursors, i believe.

Wrong. Luc's code is a FOR loop - it will operate on each row which is
returned by the SELECT.

>and i also need to update the quantity of the product. not only returns
>values/display the values. so, i guess, i need cursors and updating the
>product qty itself.

It IS a cursor. Inside the block enclosed by the FOR loop you can run your
update statement.

>I tried so hard with cursors, but i still can't make it work.

Use Luc's example - it is an example of a Firebird PSQL cursor doing its work.

heLen