meta data for this page
Creating a consistency query
Principle
A consistency query is used to find anomalies in the data. Technically, the same result could be obtained by constructing a simple inquiry, but it is often easier to express the criteria that records must meet than those that they must not meet.
The steps for creating a consistency query are identical to those for a inquiry, except for one difference: the choice of filters.
In the criteria entry interface, we find the classic tools (see dedicated page), with in addition a button: It allows you to copy a selected criterion from the
If…
area to the Then…
area or vice versa.
Contrary to inquiry, there are 2 zones to enter criteria:
- IF …
- Then…
it's mandatory to enter at least a criterion in
If…
and one inThen…
Example
- Criterion
If…
⇒ SHKCOO = '00001'. - Criterion
Then
⇒ SHDCTO = 'SQ'
Case 1
- Criterion
If…
set toRespected
. - Criterion
Then…
set onRespected
⇒ We get the records for which SHKCOO = '00001' and SHDCTO <> 'SQ'.
Case 2
- Criterion
If…
set toRespected
. - Criterion
Then…
positioned onNot respected
⇒ We retrieve the records for which SHKCOO = '00001' and SHDCTO = 'SQ'.
Case 3
- Criterion
If …
set toNot met
. - Criterion
So…
positioned onRespected
⇒ We retrieve the records for which SHKCOO <> '00001' and SHDCTO <> 'SQ'…
Case 4
- Criterion
If …
set toNot met
. - Criterion
Then…
positioned onNot respected
⇒ We retrieve the records for which SHKCOO <> '00001' and SHDCTO = 'SQ' (in this case none)