Extraction Filter
Use an extraction filter to filter the entities and relationships to be extracted.
Extraction Filter Component
Each extraction filter contains the following elements.
Input Item | Data Type | Description |
---|---|---|
entityFieldName | String | The field name of the entity to be extracted. The name is mapped to the column name in the WHERE clause. |
participantFieldName | String | The name of the relationship, which consists of the participant name and the field name of the participant separated by dot. The name is mapped to the column name of the WHERE clause.
createTimestamp and updateTimestamp are also supported for timestamp-based filter criteria. |
where | String | The
where element is mapped to the operator of the WHERE clause and the value is mapped to the value of the WHERE clause.
The operator is an SQL operator such as ">", "<", "=", or "like". |
orWhere | String | The
orWhere element is mapped to the operator of the WHERE clause and the value is mapped to the value of the WHERE clause.
The operator is an SQL operator such as ">", "<", "=", or "like". |
Multiple Filters
Each instance of the extraction filter is mapped to a condition in the SQL WHERE clause (WHERE <column> <operator> <value>).
When multiple extraction filter instances are specified for the same entity or relationship, each of them is AND'ed if the operator and value are specified using the where element. Conditions are OR'ed together if the operator and value are specified using the orWhere element.
WHERE id > '345' OR id 'like%345%'
If the first filter uses the orWhere element, SmartMapper always treats it as where element .
Limitations
- Filtering criteria cannot be parenthesized.
- When adding two filters and each filter is a different participant, the filters are only combined as OR; and if one filter is a participant and the other filter is a createTimestamp, the two filters are also only combined as OR.
- When adding filters for timestamps, the filter names must only be createTimestamp or updateTimestamp.