Karly Stack
Karly Stack

Reputation: 1

Query Results Not Writing to Table

I am trying to write the results of a query to an existing table. Recently, there has been no data written to the table, but the status says the task was completed. Any ideas what the issue could be?

"configuration": {
  "query": {
   "query": --,
   "destinationTable": {
    "projectId": --,
    "datasetId": --,
    "tableId": --
   },
   "createDisposition": "CREATE_IF_NEEDED",
   "writeDisposition": "WRITE_APPEND",
   "priority": "INTERACTIVE",
   "allowLargeResults": true,
   "useQueryCache": true,
   "useLegacySql": false
  }
 },
 "status": {
  "state": "DONE"
 },

Upvotes: 0

Views: 63

Answers (1)

Mikhail Berlyant
Mikhail Berlyant

Reputation: 173190

state can be PENDING, RUNNING or DONE

DONE means query is completed

But to see if it is successfully completed or now you need to check status.errorResult

Upvotes: 1

Related Questions