construct_table_query: Construct a query, given schema, table, columns, filter...

View source: R/pmap_db_utilities.R

construct_table_queryR Documentation

Construct a query, given schema, table, columns, filter condition

Description

Internal function to construct query given user arguments

Usage

construct_table_query(
  schema = "dbo",
  table,
  columns = NULL,
  max_rows = NULL,
  filter_condition = NULL
)

Arguments

schema

database schema name, string;default="dbo"

table

database table name, string

columns

character vector of columns; default is NULL, which returns all columns

max_rows

maximum number of rows to return; default is NULL (all rows), currently returns TOP max_rows from table

filter_condition

string representing 'WHERE' clause of query; default is NULL (no filter)

Value

query string

Examples

construct_table_query(myschema, mytable, col_list, 1000, my_filter)

lmullany/pmap_utilities documentation built on July 30, 2023, 8:54 a.m.