gor_create: gor_create

View source: R/gor_create.R

gor_createR Documentation

gor_create

Description

Creates a partial-application of gor_query in the context of conn and the listed relations in the ... arguments

Usage

gor_create(
  ...,
  defs = NULL,
  conn = NULL,
  replace = NULL,
  query.service = "queryserver"
)

Arguments

...

ellipse for the relations to include

defs

definitions string

conn

connection object from platform_connect

replace

replace a previously created gor_create closure. When supplied, the two will be merged, overwriting existing values with the current values if they have been previously defined

query.service

query service to use - either 'queryservice' (old) or 'queryserver' (new). Default: queryservice

Details

Relations can be either local dataframes (uploaded) or string queries(turned into create statements and prepended to the query when executed).

Value

partial-application of function gor_query with the conn and relations parameters set.

Examples

## Not run: 
query <- gor_create(conn = conn)
query <- gor_create(air = airquality, replace = query)
query("nor [air] | where Month=8")
months_df <- data.frame(id = 1:12, MonthName = month.abb)
query <- gor_create(months = months_df, replace = query)
query("nor [air] | map -c Month [months]")

## End(Not run)

wuxi-nextcode/gorr documentation built on Jan. 1, 2023, 7:54 a.m.