Sometimes its useful to find how many model's logic is not upto date using plsql API. One simple example would be for during republish of the model - if model logic is not upto date at the time of publication processing, publication program will fail and model will not be published. Following block can be handy before running any publication or locally creating configuration for the model using CIO API.
p_model_id NUMBER := 1774920;
CZ_PB_MGR.IS_MODEL_UPTO_DATE( P_MODEL_ID =>p_model_id, X_RETURN_STATUS =>x_return_status, X_MSG_DATA =>x_msg_data);
dbms_output.put_line('X_RETURN_STATUS = ' || X_RETURN_STATUS);
dbms_output.put_line('X_MSG_DATA = ' || X_MSG_DATA);
If x_return_status=1 then logic is not upto date, 0 value means logic is upto date.