Using the BigQuery command-line tool, how can I check if a dataset exists before creating it?
bq mk dataset
reports an error if you try to call it on an already existing dataset.
A shorter solution:
bq show $dataset || bq mk $dataset
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With