Class: sql

Adaptor~sql(sqlQuery, options) → {Operation}

new sql(sqlQuery, options) → {Operation}

Execute an SQL statement
Parameters:
Name Type Description
sqlQuery function a function which takes state and returns a string of SQL.
options object Optional options argument
Source:
Returns:
Type
Operation
Example
sql(state => `select(*) from ${state.data.tableName};`, { writeSql: true })