2

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 browser for login, so oauth seems to be working correctly. However, when I try to run a query, such as DBI::dbReadTable(con, "A549_raw_merged_TADs")[1:6, ], I get the error Error: The project variant-annotation has not enabled BigQuery. [invalid].

I am sure I need to enable something else in the project on the Google side, but I'm not sure what I need to enable, or how to do that from the web console interface.

Is this documented anywhere, or can anyone here give me instructions?

Note: I have confirmed that the BigQuery API has Activation status of Enabled via the console at https://console.cloud.google.com/apis/api/bigquery-json.googleapis.com/overview, so although my question is the same as Error processing job: Project has not enabled BigQuery, the issue appears to be different.

Additional information: when I check the BigQuery API status via the console link above, there's a notification that "To use this API, you may need credentials. Click 'Create credentials' to get started."

So it may be that my assumption that oauth seems to be working is not correct.

4
  • That console says the activation status is enabled, but there's a message "To use this API, you may need credentials. Click 'Create credentials' to get started." So perhaps the oauth is not sufficient? Commented Mar 6, 2019 at 21:01
  • 2
    you can enable the BigQuery API with this command gcloud services enable bigquery.googleapis.com, but, since you mention it is already enabled, I wonder if you are pointing at the correct project. Is "variant-annotation" your project's id? Commented Mar 6, 2019 at 21:11
  • Ah! That may be the key - that's the project's name! The id is the name followed by some numbers! With the correct project id, I get a Auto-refreshing stale OAuth token. Followed by a different error to track down - dataset not found. Thanks! If you submit your comment as an answer, I'll mark it accepted! Commented Mar 6, 2019 at 21:15
  • Possible duplicate of Error processing job: Project has not enabled BigQuery Commented Jun 25, 2019 at 3:35

1 Answer 1

3

You can enable the BigQuery API with this command gcloud services enable bigquery.googleapis.com, but, since you mention it is already enabled, you may be pointing to a different project.

Feel free to ping me on a new thread if you require assistance on the new issue.

Sign up to request clarification or add additional context in comments.

3 Comments

Thanks, I got the dataset not found error straightened out, too. Cheers!
@bheavner how did you resolve this issue? I am experiencing an error where google cloud is pointing to the wrong project for some reason
@Megan The answer to the "wrong project" question is here.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.