Skip to main content

@terascope/sql-builder / statement

statement

Interfaces​

InterfaceDescription
SQLQueryPartsThe parts of a SQL statement, before they are joined.

Functions​

buildSQLStatement()​

buildSQLStatement(parts, params, dialect): string

Defined in: statement.ts:32

Build a complete, executable SQL statement from its parts.

This is the SQL counterpart of restrictSearchQuery. Callers should use it rather than joining the parts themselves, since leaving out select would return restricted columns.

Parameters​

ParameterType
partsSQLQueryParts
paramsSQLSearchParams
dialectSQLDialect

Returns​

string