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?