What happens when bigquery upload job fails after loaded a portion of the JSON file? -


as title mentioned, happens when start bigquery upload job and, let's say, after loading 50% of rows in json file job failed. bigquery rollback of load job or left 50% of data loaded?

i appending data daily single table , keeping duplicate-free important. using http rest api

bigquery appends data atomically. never half of data in table if load fails. if job completes successfully, of data show @ once.

there 2 additional tricks can use prevent duplicates:

  1. specify job id load job. imagine pull network cable mid way through starting job... how know whether succeeded? specifying job id lets job later if job creation request fails.

  2. perform loads temporary table, , specify write_truncate writedisposition. means can run import jobs idempotently temporary table, , if don't know whether job succeeded, run one, , overwrite data. once have load job completes successfully, run table copy job writedisposition write_append append new data main table.


Comments

Popular posts from this blog

html - How to style widget with post count different than without post count -

How to remove text and logo OR add Overflow on Android ActionBar using AppCompat on API 8? -

javascript - storing input from prompt in array and displaying the array -