Only records matching the filter criteria are let through to the <load> element.
Required: A reference to a field in the data file; for example, field="${part}".
One of the following values:
EQ—equals (default value)
NE—not equals
GT—greater than
GE—greater or equals
LT—less than
LE—less or equals
IN—in
NI—not in
LIKE—regular expression match
NOTLIKE—inverse of LIKE
Required: Value against which the field’s value is compared. This can be a load-function expression if relop is EQ, NE, GT, GE, LT, or LE.
The filter criteria is expressed as a field relop value, and only those records for which the expression is true are let through.
Following are some examples using <simple-filter>:
Include only data records where location is not null:
<stage-rowsource rowsource="Parts"> <simple-filter field="${location}" relop="NE" value=""/> ... </stage-rowsource>
Include only data records where req_elem is SB, AR or BB:
<stage-rowsource rowsource="MRP"> <simple-filter field="${req_elem}" relop="IN" value="SB,AR,BB"/> ... </stage-rowsource>
Include only data records where part begins with fg:
<stage-rowsource rowsource="FinishedGoods"> <simple-filter field="${part}" relop="LIKE" value="fg.*"/> ... </stage-rowsource>
Include only data records where builddate is after exportdate:
<stage-rowsource rowsource="PlannedBuilds"> <simple-filter field="${builddate}" relop="GT" value="${exportdate}"/> ... </stage-rowsource>
Include only data records where builddate is in the future:
<stage-rowsource rowsource="PlannedBuilds"> <simple-filter field="${builddate}" relop="GT" value="$today"/> ... </stage-rowsource>
Include only those records where orderdate is after 6/1/2009:
<stage-rowsource rowsource="Orders"> <${orderdate}> relop="GE" value="$date(6/1/2009,MM/dd/yyyy)"/> </stage-rowsource>