bigQueryR (version 0.2.0)

bqr_query: Query a BigQuery Table

Description

MaxResults is how many results to return per page of results, which can be less than the total results you have set in your query using LIMIT. Google recommends for bigger datasets to set maxResults = 1000, but this will use more API calls.

Usage

bqr_query(projectId, datasetId, query, maxResults = 1000)

Arguments

projectId
The BigQuery project ID
datasetId
A datasetId within projectId
query
BigQuery SQL
maxResults
Max number per page of results. Set total rows with LIMIT in your query.

Value

a data.frame. If there is an SQL error, a data.frame with additional class "bigQueryR_query_error" and the problem in the data.frame$message

Examples

Run this code

## Not run: 
# 
# bqr_query("big-query-r","samples",
#           "SELECT COUNT(repository.url) FROM [publicdata:samples.github_nested]")
# 
# ## End(Not run)

Run the code above in your browser using DataLab