Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -28,5 +28,5 @@ Suggests:
testthat,
data.table,
purrr
RoxygenNote: 7.1.1
RoxygenNote: 7.3.1
VignetteBuilder: knitr
8 changes: 7 additions & 1 deletion R/query.R
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
#' @param projectId The BigQuery project ID
#' @param datasetId A datasetId within projectId
#' @param query BigQuery SQL. You can also supply a file location of your query ending with \code{.sql}
#' @param labels Labels to tag to job in list format. lower-case only. Default empty list
#' @param maxResults Max number per page of results. Set total rows with LIMIT in your query.
#' @param useLegacySql Whether the query you pass is legacy SQL or not. Default TRUE
#' @param useQueryCache Whether to use the query cache. Default TRUE, set to FALSE for realtime queries.
Expand Down Expand Up @@ -33,6 +34,7 @@
bqr_query <- function(projectId = bqr_get_global_project(),
datasetId = bqr_get_global_dataset(),
query,
labels = list(),
maxResults = 1000,
useLegacySql = TRUE,
useQueryCache = TRUE,
Expand All @@ -50,6 +52,7 @@ bqr_query <- function(projectId = bqr_get_global_project(),
body <- list(
kind = "bigquery#queryRequest",
query = query,
labels = labels,
maxResults = maxResults,
useLegacySql = useLegacySql,
useQueryCache = useQueryCache,
Expand Down Expand Up @@ -125,6 +128,7 @@ bqr_query <- function(projectId = bqr_get_global_project(),
#' @param projectId projectId to be billed.
#' @param datasetId datasetId of where query will execute.
#' @param query The BigQuery query as a string.
#' @param labels Labels to tag to job in list format. lower-case only. Default empty list
#' @param destinationTableId Id of table the results will be written to.
#' @param writeDisposition Behaviour if destination table exists. See Details.
#' @param useLegacySql Whether the query you pass is legacy SQL or not. Default TRUE
Expand Down Expand Up @@ -202,6 +206,7 @@ bqr_query <- function(projectId = bqr_get_global_project(),
bqr_query_asynch <- function(projectId = bqr_get_global_project(),
datasetId = bqr_get_global_dataset(),
query,
labels = list(),
destinationTableId,
useLegacySql = TRUE,
writeDisposition = c("WRITE_EMPTY",
Expand Down Expand Up @@ -239,7 +244,8 @@ bqr_query_asynch <- function(projectId = bqr_get_global_project(),
query = query,
useLegacySql = useLegacySql,
writeDisposition = writeDisposition
)
),
labels = labels
)
)

Expand Down
10 changes: 10 additions & 0 deletions man/bigQueryR.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions man/bqr_query.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions man/bqr_query_asynch.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.