Welcome to ExamTopics
ExamTopics Logo
- Expert Verified, Online, Free.
exam questions

Exam Professional Cloud Developer All Questions

View all questions & answers for the Professional Cloud Developer exam

Exam Professional Cloud Developer topic 1 question 65 discussion

Actual exam question from Google's Professional Cloud Developer
Question #: 65
Topic #: 1
[All Professional Cloud Developer Questions]

Your analytics system executes queries against a BigQuery dataset. The SQL query is executed in batch and passes the contents of a SQL file to the BigQuery
CLI. Then it redirects the BigQuery CLI output to another process. However, you are getting a permission error from the BigQuery CLI when the queries are executed.
You want to resolve the issue. What should you do?

  • A. Grant the service account BigQuery Data Viewer and BigQuery Job User roles.
  • B. Grant the service account BigQuery Data Editor and BigQuery Data Viewer roles.
  • C. Create a view in BigQuery from the SQL query and SELECT* from the view in the CLI.
  • D. Create a new dataset in BigQuery, and copy the source table to the new dataset Query the new dataset and table from the CLI.
Show Suggested Answer Hide Answer
Suggested Answer: A 🗳️

Comments

Chosen Answer:
This is a voting comment (?). It is better to Upvote an existing comment if you don't have anything to add.
Switch to a voting comment New
donchick
Highly Voted 3 years, 11 months ago
I think A is the correct one.
upvoted 14 times
...
thewalker
Most Recent 4 months, 1 week ago
Selected Answer: A
The correct answer is A. Grant the service account BigQuery Data Viewer and BigQuery Job User roles. Here's why: BigQuery Data Viewer: This role allows the service account to read data from BigQuery tables. This is necessary for the BigQuery CLI to execute the SQL queries. BigQuery Job User: This role allows the service account to run queries and jobs in BigQuery. This is essential for the BigQuery CLI to execute the SQL queries and return results.
upvoted 1 times
thewalker
4 months, 1 week ago
Let's break down why the other options are less suitable: B. Grant the service account BigQuery Data Editor and BigQuery Data Viewer roles: While BigQuery Data Editor allows for data modification, it's not strictly necessary for executing queries. Granting BigQuery Data Viewer and BigQuery Job User roles is sufficient. C. Create a view in BigQuery from the SQL query and SELECT from the view in the CLI: * Creating a view can simplify queries, but it doesn't address the underlying permission issue. The service account still needs the necessary permissions to access the view and execute queries. D. Create a new dataset in BigQuery and copy the source table to the new dataset Query the new dataset and table from the CLI: This approach adds unnecessary complexity and data movement. It doesn't solve the permission issue.
upvoted 1 times
...
...
santoshchauhan
8 months, 3 weeks ago
Selected Answer: A
A. Grant the service account BigQuery Data Viewer and BigQuery Job User roles. The permission error from the BigQuery CLI suggests that the service account used to execute the queries does not have the necessary permissions. To resolve this, you need to ensure that the service account has the appropriate roles: BigQuery Data Viewer role: This role allows the service account to read data from BigQuery tables and views. It's necessary for the service account to access and read the dataset against which the queries are being executed. BigQuery Job User role: This role allows the service account to create and run jobs in BigQuery, including query jobs, which is necessary for executing SQL queries.
upvoted 1 times
...
theseawillclaim
9 months, 2 weeks ago
Selected Answer: A
A is the one. No need to edit data is specified.
upvoted 1 times
...
__rajan__
1 year, 2 months ago
Selected Answer: A
A is correct.
upvoted 1 times
...
omermahgoub
1 year, 10 months ago
The correct answer is Option A. In order to allow the analytics system to execute queries against the BigQuery dataset, the service account must be granted the BigQuery Data Viewer and BigQuery Job User roles. The BigQuery Data Viewer role allows the service account to read data from tables, and the BigQuery Job User role allows the service account to run jobs, which includes executing queries. Option B is not a good solution because the BigQuery Data Editor role allows the service account to modify data in tables, which is not necessary to execute queries. Option C is not a good solution because creating a view in BigQuery and selecting from the view in the CLI will not resolve the permission issue. Option D is not a good solution because creating a new dataset and copying the source table to the new dataset will not resolve the permission issue.
upvoted 3 times
...
tomato123
2 years, 3 months ago
Selected Answer: A
A is correct
upvoted 3 times
...
maxdanny
2 years, 4 months ago
Selected Answer: A
A it's correct for the principle of least privilege
upvoted 1 times
...
ParagSanyashiv
2 years, 10 months ago
Selected Answer: A
According to the best practice - "User should have least privilege i.e. only those permissions which are required to perform an operation" - Option A is Correct.
upvoted 1 times
...
syu31svc
3 years, 4 months ago
Principle of least privilege so A is the answer
upvoted 3 times
...
cloud_mk
3 years, 8 months ago
Ans A only https://cloud.google.com/bigquery/docs/access-control#bigquery In Ans B Bigquery Data Editor is not required.
upvoted 4 times
...
Community vote distribution
A (35%)
C (25%)
B (20%)
Other
Most Voted
A voting comment increases the vote count for the chosen answer by one.

Upvoting a comment with a selected answer will also increase the vote count towards that answer by one. So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.

SaveCancel
Loading ...