What this is about
A filter CDMS cannot apply is never left out. The search would otherwise run without it and return more matches than you wanted. CDMS therefore has exactly two reactions:
- CDMS detects the error in the request
messageKeynames the cause, the field and often the value- the client has to correct the request
- a security filter cannot be applied
unresolvable-mandatory-filter|…- caused by the configuration, not by the request
Not a broken filter, but refused as well: a filter or an order on a field whose read role you lack. That results in 403 missing-permission|<role>. See Protected values.
All cases at a glance
| Case | Example | Response |
|---|---|---|
key missing | { "value": "x", "param": "EQ" } | 400 missing-search|key |
param explicitly null | { "key": "label", "value": "x", "param": null } | 400 missing-search|param |
param missing entirely | { "key": "label", "value": "x" } | no error: LIKE is the default |
invalid UUID with EQ or MEMBEROF | { "key": "id", "value": "no-uuid", "param": "EQ" } | 400 wrong-uuid-in-where|no-uuid |
invalid UUID with NEQ or IN | { "key": "id", "value": "no-uuid", "param": "IN" } | 400 wrong-uuid-in-where|no-uuid |
| unknown field | { "key": "nope", "value": "x", "param": "EQ" } | 400 unknown-search-key|nope |
| unknown step in the path | { "key": "firma.companyname", … } | 400 unknown-search-key|firma.companyname |
| field only a subtype has | company in a search on tenant/person | allowed, matches rows of that subtype only |
| operator does not fit the field type | label BEFORE, active AFTER | 400 unsupported-operator|label|BEFORE |
unknown enum value with EQ/NEQ | type EQ BOSS | 400 wrong-value-in-where|type|BOSS |
boolean other than true/false | active EQ yes | 400 wrong-value-in-where|active|yes |
value missing on a text field | { "key": "label", "param": "EQ" } | no matches, 200 |
value missing on another field | { "key": "dueOn", "param": "AFTER" } | 400 wrong-value-in-where|dueOn|null |
| value does not fit the type | amount EQ abc, dueOn EQ 10.02.2026 | 400 wrong-value-in-where|amount|abc |
unknown enum value with IN | type IN CEO,BOSS | 400 wrong-value-in-where|type|BOSS |
LIKE on a number | amount LIKE 1% | 400 like-needs-text|amount |
| operator unknown or in lower case | "param": "eq", "param": "FOO" | 400 invalid-value|parameter.query.filter[0].param |
MEMBEROF on a non-list | label MEMBEROF x | 400 memberof-needs-collection|label |
| unknown sort field | { "field": "nope", "order": "ASC" } | 400 wrong-order-element-exception |
| sort direction in lower case | "order": "desc" | 400 invalid-value|parameter.order[0].order |
parameter explicitly null | "parameter": null | 400 missing-parameter |
| mandatory filter not applicable | attribute filter on a field that does not exist | 500 unresolvable-mandatory-filter|… |
| attribute for the attribute filter missing in the profile | profile without company | 422 missing-attribute-on-profile|company |
How CDMS checks a filter
-
1CDMSlooks up the field from
keyin the model, step by step along the path; for an abstract model also in its subtypes -
2CDMSchecks whether the operator fits the field type:
AFTERandBEFOREexist for dates, times and numbers -
3CDMSconverts the value into the type of the field
-
4CDMS→Databaseruns the search with all filtersResult: If a check fails, CDMS answers 400 and names the field, the operator or the value. The search does not run at all.
This holds in every mode, outside the strict mode as well. For the filters that always run along it is a 500: a security filter that cannot be applied is caused by the configuration, not by your request.
How to find the error
When: The search returns more than expected, maybe everything.
Does every group have a type? Without type the group is OR, see AND/OR groups. Is a filter in the wrong group? A typo in key is no longer the cause, it leads to 400.
Result: Usually a forgotten type.
When: The search returns nothing, although matching data exists.
LIKE without %? Spaces in an IN list? Is an alternative in an AND group instead of an OR group? Or the data is invisible to this person.
Result: Usually a missing % or a security filter.
When: Response with messageKey.
The messageKey names the cause, the field and the value, e.g. unknown-search-key|firma.companyname for a typo in the path, unsupported-operator|label|BEFORE, wrong-value-in-where|dueOn|10.02.2026 or invalid-value|parameter.query.filter[0].param for an operator in lower case.
Result: Correct the named key, operator or value. For date values, see Date and time values.
When: messageKey is unresolvable-mandatory-filter|….
A filter that always runs along cannot be applied, for example an attribute filter on a field that does not exist. This is caused by the configuration of the model, not by your request.
Result: Have the modeling checked, see Filters that always run along.