Please enable JavaScript to view this site.

Invantive Estate

In this form you can register and change attribute rules.Open screen in browser Open Form

An attribute rule is a specification of a business rule. There are two types of attribute rules:

checks on validity: attribute rules that impose requirements on data to approve them. Examples are ‘the amount of the invoice line must be different than 0’ or ‘the user being the task owner must have checked the task owner flag’.

actions: actions are pieces of programs being executed under special conditions.

Actions can be classified in two sorts of actions:

actions being executed before a changed piece of data is stored, for example, when entering the default or constant values in fields.

actions being executed after a changed piece of data is stored, for example, when sending an email.

The registration of attribute rules is a typical activity for application developers. See the warning under Application Development.

Attribute Rules Screen

The meaning of the entry fields is:

Application

The application of which the attribute rule is part.

Table Code

The table and the related business view of which the attribute rule is part of.

Code

The unique code of an attribute rule.

Sort Order

A numeric value used to sort the referential rules in terms of sequence of execution.

Event Category

The sort of event that triggers the processing of the attribute rule. The following events can occur:

A: Every event (edit, add or delete)

M: Mutation (edit or delete)

I: add

U: edit

D: delete

Action Category

The action category. The following kinds of actions can occur:

E: validity check.

A: action.

Action Moment

Has meaning only if the action category ‘Action’ is selected. The moment on which an action is executed: before or after executing the event.

Create

Checked in case the attribute rule needs to be included in the business layer.

Constraint Specification

Limiting condition which needs to be met aside of the event category, expressed as a SQL where clause.

You can refer to the table's respective row with the following texts:

‘: old’: the value of the row before the event (empty in case of adding).

‘: new’: the value of the row after the event (empty in case of deleting)

‘: last’: the last known value of the row (equivalent to ‘: new’ in case of adding or changing and equal to ‘: old’ in the case of deleting).

‘: event’: the type of event, with the following possible values: ‘insert’, ‘update’ and ‘delete’.

Action Specification

Has meaning only if the action category ‘Action’ has been selected. Specification in the PL/SQL of the to be executed action.

You can refer to the table's respective row with the following texts:

‘: old’: the value of the row before the event (empty in case of adding).

‘: new’: the value of the row after the event (empty in case of deleting)

‘: last’: the last known value of the row (equivalent to ‘: new’ in case of adding or changing and equal to ‘: old’ in the case of deleting).

‘: event’: the type of event, with the following possible values: ‘insert’, ‘update’ and ‘delete’.

User Message

Has meaning only if the action category ‘Validity Check’ has been selected.

The message which warns you, in case the row does not meet the validity check.

Documentation

Documentation of the attribute rule.

Attribute rules offer many options. Below are some examples.

Enter an amount greater or less than 0 for a contract.

Action category:        E

Specification:        :last.odt_bedrag_verlening is null or :last.odt_bedrag_verlening<>0

Other:                None.

Only óne row of settings is allowed.

Action category:        E

Specification:        :last.isg_seq = 1

Other:                Make a unique index on column ‘seq’.

A role can only have the rights to change all projects when the role also has the rights to see all projects.

Action category:        E

Specification:        :last.rol_alle_prjctn_wijzigen_vlag = ‘N’ or ( :last.rol_alle_prjctn_wijzigen_vlag = ‘Y’ and :last.rol_alle_prjctn_zien_vlag = ‘Y’)

Other:                None.

The project type cannot be changed to Master Project in case a project has costs categories, revenues, orders, invoice rules, last estimates or contract budgets.

Action category:        E

Specification:        :last.pjt_projectvorm_ind in (‘S’, ‘I’) or ( :last.pjt_projectvorm_ind = ‘M’ and not exists ( select 1 from bubs_kostenplaatsen_v where pjt_id = :last.pjt_id ) )

Other:                None.

This cost type prefix is used already in this master project.

Action category:        E

Specification:        (:last.pjt_projectvorm_ind in (‘M’, ‘I’) or ( :last.pjt_projectvorm_ind = ‘S’ and not exists ( /* Another subproject of the same master project with the same prefix. */ select 1 from bubs_projecten_v where pjt_projectvorm_ind =‘S’ and pjt_code <> :last.pjt_code and hpt_code = :last.hpt_code and pjt_volgnummer_prefix = :last.pjt_volgnummer_prefix)))

Other:                None.

New access requests always have an open status.

Action category:        A

Action moment:        B

Specification:        1=1

Action specification:        :new.atg_afgesloten_vlag := ‘N’;

Other:                None.

Send an email when a process is changed.

Action category:        A

Action moment:        A

Specification:        1=1

Action specification:        bubs#processen.send_message(:old, :new, :last);

Other:                None.

If possible, change the status of the background process from F (input parameters) to P (planned) when a parameter is updated.

Action category:        A

Action moment:        B

Specification:        1=1

Action specification:        update bubs_background_jobs_v set bjb_status_ind=‘P’ where 1=1 and bjb_status_ind=‘F’ and bjb_id = :new.bjb_id;

Other:                None.