05-17-2022 06:36 AM
hi all,
Currently, i am trying to write an empty delta file in data lake, to do this i am doing the following:
df=spark.read.format('parquet').load(landingZonePath)
df.write.format("delta").save(centralizedZonePath)
Note: Parquet file in landingzone, has the schema
06-01-2022 08:20 PM
Hi @bhagya s Since your source file is empty, there is no data file inside the centralizedZonePath directory i.e .parquet file is not created in the target location. However, _delta_log is the transaction log that holds the metadata of the delta format data and has the schema of the table.
You may understand more about transaction logs here :https://databricks.com/discover/diving-into-delta-lake-talks/unpacking-transaction-log
05-17-2022 09:52 AM
@bhagya s , File schema is in _delta_log
05-18-2022 09:50 PM
Hi @bhagya s , Just a friendly follow-up. Do you still need help, or @Hubert Dudek (Customer) 's response help you to find the solution? Please let us know.
06-01-2022 08:20 PM
Hi @bhagya s Since your source file is empty, there is no data file inside the centralizedZonePath directory i.e .parquet file is not created in the target location. However, _delta_log is the transaction log that holds the metadata of the delta format data and has the schema of the table.
You may understand more about transaction logs here :https://databricks.com/discover/diving-into-delta-lake-talks/unpacking-transaction-log
06-14-2022 09:23 AM
Hi @bhagya s , We haven’t heard from you on the last response from @Noopur Nigam , and I was checking back to see if you have a resolution yet. If you have any solution, please share it with the community as it can be helpful to others. Otherwise, we will respond with more details and try to help.
Join a Regional User Group to connect with local Databricks users. Events will be happening in your city, and you won’t want to miss the chance to attend and share knowledge.
If there isn’t a group near you, start one and help create a community that brings people together.
Request a New Group