make_tbl_output: Make table output from a SQL query

View source: R/utils.R

make_tbl_outputR Documentation

Make table output from a SQL query

Description

This function is used at the end of user-facing functions to query the database. It limits the query to some number of rows and collects if if specified.

Usage

make_tbl_output(tbl, limit, lazy)

Arguments

tbl

A query from conn with dbplyr and lazily evaluated.

limit

LIMIT of the query. A positive integer or Inf. Default is Inf, in which case all records are returned.

lazy

If TRUE, does not collect() the query into a dataframe. This is useful if other tables from the database are joined later on.

Value

A query, evaluated with limit and lazy.


f-hafner/magutils documentation built on Sept. 20, 2023, 5:05 a.m.