Skip to Main Content

Oracle Forms

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Using a CASE statement in a trigger on Oracle Forms

2893145May 20 2015 — edited May 21 2015

This is my scenario

I have a form which has a field called DORMANT.

I want to change the data using a case but I am not sure where abouts in the form to put it.

This is my code

DECLARE

ls_dormant VARCHAR2(5);

CURSOR c1 IS

SELECT CASE WHEN dormant = 1 THEN 'Yes'

                    ELSE 'No'

                         END dormant

FROM ybshr

BEGIN

FOR i IN c1 LOOP

     ls_dormant := i.dormant;

END_LOOP;

block.dormant := ls_dormant;

END;

I have also tried this using a OPEN, FETCH, CLOSE cursor.  But neither are working.

I have run my code in PLSQL Developer and it works, it just doesnt work when I run my form.

Which trigger should I use, and where abouts?

Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Jun 18 2015
Added on May 20 2015
12 comments
3,157 views