Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Old and new values in Oracle Form

I'm working with Oracle Forms. I have a field named SOLD_TO_CUST_PARTY_NAME. I have to execute a process if I detect a change in the field's value. I tried using when_validate, but it's executed even if you just click the field and move to another field (validation ALWAYS occurs whether you change the value or not). Is there anyway I can check :old and :new or something similar to execute a process only if the field is modified?

EDIT: Can't use personalizations. It has to be done with pl/sql.

like image 839
Nacho321 Avatar asked Sep 26 '12 17:09

Nacho321


1 Answers

There is a property called database value that let you check if the field has been modified and if it has not you just have to exit the validation trigger.

Ex.

    BEGIN

    IF :BLOCK.ITEM = GET_ITEM_PROPERTY('BLOCK.ITEM', database_value) THEN
     RETURN;
    END IF;

     /* VALIDATION */

    END;
like image 185
Laggel Avatar answered Sep 21 '22 23:09

Laggel