Questions tagged [bigrquery]

bigquery is an R package makes it easy to work with data stored in Google BigQuery by allowing you to query BigQuery tables and retrieve metadata about your projects, datasets, tables, and jobs

The bigrquery package makes it easy to work with data stored in Google BigQuery by allowing you to query BigQuery tables and retrieve metadata about your projects, datasets, tables, and jobs

77 questions
2
votes
1 answer

BigQuery API Error: "The project ___ has not enabled BigQuery."

I'm trying to use bigrquery from an interactive R session for the first time. I've installed the R bigrquery package and successfully established a connection. I've authenticated following a redirect from the interactive RStudio session to the web…
bheavner
  • 519
  • 1
  • 4
  • 20
2
votes
0 answers

R cannot import data through bigrquery package - !self$finished is not TRUE

when trying to pull larger datasets from my GBQ account, I hit this error message: Error in pb_tick(self, private, len, tokens) : !self$finished is not TRUE The table I am querying is ~105GB and the same SQL query works fine in the GBQ console. It's…
1
vote
1 answer

Problem running a query in package "bigrquery" in R

I am trying to make a code in Rstudio in order to run a code that is in a path in my PC, but there is an error that I can't fix. here is my code and the error: >library(DBI) >library(bigrquery) >con <- dbConnect(odbc::odbc(), "Google Big Query",…
1
vote
0 answers

bigrquery - Get new token with a different email address

I am trying to change the email that I use to read data from bigrquery. When I use bq_auth() bq_user() I get my work email bq_user() [1] "MYEMAIL@biotech.com" If I deauth, and reauthenticate: > bq_deauth() > bq_user() NULL >…
HowYaDoing
  • 820
  • 2
  • 7
  • 15
1
vote
1 answer

R bigrquery - how to catch error messages from executed SQL?

Say I have some SQL code that refreshes a table of data, and I would like to schedule an R script to schedule this code to run daily. Is there a way to capture any potential error messages the SQL code may throw and save that error message to an R…
Hollywood
  • 334
  • 4
  • 17
1
vote
0 answers

googleCloudStorageR::gcs_auth: Error: Non-interactive session and no authentication email selected

I'd like to use this function in docker to authenticate Biq Query and Google Cloud Storage. authenticate <- function() { scopes <- c("https://www.googleapis.com/auth/cloud-platform", …
1
vote
1 answer

bigrquery: mean, max, min and sd extraction inside 5-95 quantiles using dplyr verbs doesn't work

I try to make the mean, max, min and sd extraction inside 5-95 quantiles in a BigQuery server, but dplyr verbs don't work and the output error is: x Syntax error: Expected ")" but got keyword AS at [1:117] [invalidQuery] In my…
Leprechault
  • 1,531
  • 12
  • 28
1
vote
2 answers

Operating across columns (rowwise) in R dbplyr

I opened an issue for this. But in case this is operator error and not a problem with the package, I'm posting here for coding advice. The most recent (v2.1) update to dbplyr was supposed to increase support for across and associated functions.…
abalter
  • 9,663
  • 17
  • 90
  • 145
1
vote
0 answers

How to import 11 million row table into Rstudio from Google BigQuery? [code included]

I am trying to do some data exploration for this dataset I have. The table I want to import is 11 million rows. Here is the script and output #Creating a variable for our BQ project space project_id = 'project space' #Query Step1 <- " …
Jaskeil
  • 1,044
  • 12
  • 33
1
vote
1 answer

Return quantiles within a summarise() call through dbplyr/bigRquery to BigQuery SQL database

I am attempting to get quantiles for a variable in a grouped BigQuery table, and I get this error: Error: Job 'xxxxx' failed Syntax error: Expected end of input but got keyword WITHIN at [1:45] [invalidQuery] Reprex is below. # NOTE: for reprex to…
kbmorales
  • 21
  • 3
1
vote
3 answers

Using sql chunks in Rmarkdown with query parameters

I am trying to work out if there is a way to pass parameters to the sql chunks connected to BigQuery in RMarkdown: ```{r setup} library(bigrquery) bq_auth(path = "access_token.json") db <- dbConnect( bigquery(), dataset = 'my_data', project…
Bulat
  • 6,869
  • 1
  • 29
  • 52
1
vote
1 answer

Authentication issue with R's bigrquery

This post makes it clear that the function bq_auth() should be used to authenticate BigQuery in R. However, I have created a BigQuery-Admin service account, downloaded a service account key, and have passed that key into the bq_auth() function, yet…
Canovice
  • 9,012
  • 22
  • 93
  • 211
1
vote
1 answer

BigRQuery How to update a column in a table on google big query?

I am struggling to update a table in Google BigQuery using the BigRQuery package in R. I have only managed to patch the new column names but not to update the values. Here is my code so far: library(bigrquery) library(tidyverse) projectId =…
Jean_N
  • 489
  • 1
  • 4
  • 19
1
vote
1 answer

Generate BigQuery code from dplyr code *without* actually executing BigQuery?

We can see here some simple instructions on how to use tidyverse principles to wrangle data using bigquery using the R packages bigrquery and dbplyr. This works by taking regular dplyr code and when the user calls %>% collect(), it translates the…
stevec
  • 41,291
  • 27
  • 223
  • 311
1
vote
0 answers

How to solve 'Failed to parse' problem to download a table using bigrquery

I´m using R and bigrquery package on windows 10 to acces some data bases from bigquery. All works perfect but when a try to download a table with bq_table_download function, I obtain this error: Error in bq_parse_files(schema_path, page_paths, n =…