Ich bin neu in Python hatte ich diesen Code verwendenWie Verbindung mit BigQuery machen mit Python
from google.cloud import bigquery
from google.cloud.bigquery import SchemaField
client = bigquery.Client(project='xxxxxxxxxxxxx')
ich diesen Fehler bin geting
C:\Python27\python.exe "C:/Users/Vikas Chauhan/python_programs/bigQuery.py"
Traceback (most recent call last):
File "C:/Users/Vikas Chauhan/python_programs/bigQuery.py", line 5, in <module>
client = bigquery.Client(project='stellar-display-145814')
File "C:\Python27\lib\site-packages\google\cloud\bigquery\client.py", line 83, in __init__
project=project, credentials=credentials, _http=_http)
File "C:\Python27\lib\site-packages\google\cloud\client.py", line 212, in __init__
Client.__init__(self, credentials=credentials, _http=_http)
File "C:\Python27\lib\site-packages\google\cloud\client.py", line 128, in __init__
credentials = get_credentials()
File "C:\Python27\lib\site-packages\google\cloud\credentials.py", line 39, in get_credentials
credentials, _ = google.auth.default()
File "C:\Python27\lib\site-packages\google\auth\_default.py", line 282, in default
raise exceptions.DefaultCredentialsError(_HELP_MESSAGE)
google.auth.exceptions.DefaultCredentialsError: Could not automatically determine credentials. Please set GOOGLE_APPLICATION_CREDENTIALS or
explicitly create credential and re-run the application. For more
information, please see
https://developers.google.com/accounts/docs/application-default-credentials.
Ich hatte bereits die Umgebungsvariable gesetzt. Ich bekomme diesen Fehler immer wieder.
Ich bin neu in Python, also bitte helfen Sie mir, dies zu lösen. Ich habe kein einziges Wissen darüber, d. H. Mit Python eine Verbindung zur BigQuery herzustellen. danke
Danke, es funktioniert. Aber gibt es eine Möglichkeit, eine Verbindung mit der OAuth URL herzustellen? –