Skip to content

Find Required Reference Record

Finds exactly one required record in a Data Lake reference table.

@lainstack/reference-table/find-required-record · Data

Find Required Reference Record looks up exactly one row in a Reference Table by an exact match on one column. It returns that row under row, with rows (one item), rowCount and provenance (table, revision and row ids). Use it when the automation cannot continue without the record, such as a customer or code that must exist.

Choose @lainstack/reference-table/read instead when you need many rows, not one.

Traps:

  • The match is exact and the value is text. matchColumnId is a column id such as column-1, not a column name. matchValue can be a reference to an upstream value, and it is limited to 4,096 characters.
  • No match is not a quiet empty result. If the not_found port has a connected target, the run takes that port. row is null and reason explains the miss. If nothing is connected there, the step stops and asks a person for a corrected matchValue, then retries with it.
  • More than one match fails the step with status 409. The match column must identify a single row.
  • row can be null on the not_found path, so do not reference row fields downstream of that port.
  • A missing table fails the step.
Setting Key Type Details
Reference Table (required) referenceTableId Text Choose the reference table that must contain the record.
Match column (required) matchColumnId Text Choose the column used for the exact match. At most 160 characters.
Match value (required) matchValue Text Enter the exact value or insert an upstream value.
Output Path Type
Row row Value
Schema schema Value
Provenance provenance Record
Reason reason Record
Row Count rowCount Number
Truncated truncated Yes or no
Exit Port Notes
Out out
Not found not_found