getColumn()
Factory method to create a query function to return an array of values from a single column.
Method signature
getColumn({ name?: string, columnName: string, columnType: ColumnDefinition, query: GenericQueryFunction})
name
- optional name for loggingcolumnName
- the column to return values fromcolumnType
- column returned from the query. See column conceptsquery
- function which returns the query to be executed. See querying
Return value
An async query function. Invoking this function with the arguments required by query
will execute the query and return the results from the column specified by columnName
Query results
[]
if no rows were returned from the query- Array of
columnName
values