Skip to content

buildWhereClause

buildWhereClause(node, parentFieldName, soqlFilterableFields): string

Defined in: fieldHistory.ts:103

Build a SOQL WHERE clause from the subset of a filter tree that references SOQL-filterable fields. Conditions on any other field are left for recordMatchesClientFilters to apply after the query runs.

FilterGroup | undefined

The filter tree (or subtree) to build a clause from.

string

The history object’s real parent lookup field, substituted for the 'ParentId' placeholder.

ReadonlySet<string>

Fields that can be safely pushed into the SOQL WHERE clause; conditions on any other field are omitted here.

string

The WHERE clause body (no leading WHERE), or '' if nothing was filterable.