VALIDATE_ROW procedure

The VALIDATE_ROW procedure is invoked when the user makes changes to a field on the user interface for which the Server Validate On Change property is enabled. You can perform any business validation or define default values to fields in PL/SQL without writing any Java Code for server-side validations.

PROCEDURE VALIDATE_ROW(
 P_ACTIVE IN OUT VARCHAR2
 , P_CREATED_BY IN OUT NUMBER
 , P_CREATION_DATE IN OUT DATE
 , P_DESCRIPTION IN OUT VARCHAR2
 , P_END_DATE IN OUT DATE
 , P_LAST_UPDATED_BY IN OUT NUMBER
 , P_LAST_UPDATE_DATE IN OUT DATE
 , P_LIST_PRICE IN OUT NUMBER
 , P_LONG_DESCRIPTION IN OUT VARCHAR2
 , P_PRODUCT_CODE IN OUT VARCHAR2
 , P_PRODUCT_ID IN OUT NUMBER
 , P_PRODUCT_NAME IN OUT VARCHAR2
 , P_START_DATE IN OUT DATE
 , P_CHANGED_ATTRIBUTE IN OUT VARCHAR2
 , P_CHANGED_ATTRIBUTE_OLD_VALUE IN OUT VARCHAR2
 );

All the parameters are of the type IN OUT. You can set or change any field values in the VALIDATE_ROW procedure and they get reflected in the UI.

P_CHANGED_ATTRIBUTE has the name of the parameter, the changes to which triggered the VALIDATE_ROW call. For example, if the user changes the Product Name field on the user interface, P_PRODUCT_NAME will be the changed attribute.

P_CHANGED_ATTRIBUTE_OLD_VALUE will contain the old value of the parameter that was set before it was updated by the user. If there was no value initially, it is set to NULL. The actual parameter, P_PRODUCT_NAME in this case, will have the new value.

Last updated