-
Notifications
You must be signed in to change notification settings - Fork 2
DbQueryAnd
do- edited this page Feb 19, 2024
·
3 revisions
DbQueryAnd
is a class representing SQL boolean term:
<boolean factor> [AND <boolean term> AND <boolean factor> AND...]
Name | Type | Description |
---|---|---|
filters |
Array | list of {sql, params} objects, such as DbQueryTableColumnComparison instances |
sql |
String | The SQL fragment to be interpolated in the query: all filters ' sql concatenated with AND
|
params |
Array | The list of parameters corresponding to all ? placeholders in sql : all filters ' params merged together |
For a given filters
list, removes all null
entries from it and then:
- if not one entry is left, returns
null
; - if a single filter is left, returns it;
- otherwise, constructs and returns the corresponding
DbQueryAnd
instance.