preAction in databricks while writing into Google Big Query Table?
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-19-2023 08:58 PM
I am writing into Google Big Query table using append mode. I need to delete current day data before writing new data. I just want to know if there is any preActions parameter can be used to first delete data before writing into table? Below is the syntax but preActiones is not working in this:
(DF.write
.format("bigquery")
.option("temporaryGcsBucket", "Bucket-Name")
.option("preActions","Truncate table `Table-Name`")
.mode("append")
.option("credentialsFile",credentialfilepath)
.option("parentProject",projectName)
.option("table", "Table-Name")
.save()
)
Labels:
- Labels:
-
Azure databricks