Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-01-2024 03:03 PM
Hello ,
This is an underlying exception that should occur with any SQL statement that require access to this file:
part-00000-36ee2e95-cfb1-449b-a986-21657cc01b22-c000.snappy.parquet
It looks like the Delta log is referencing a file that doesn't exist anymore. This could happen if the file was removed by vacuum or if the file was manually deleted.
Could you please share the results of the commands below?
# Check added files
(
spark
.read
.json("s3://avinashkhamanekar/tmp/test_table_original12/_delta_log/",
pathGlobFilter="*.json")
.withColumn("filename", f.input_file_name())
.where("add.path LIKE '%part-00000-36ee2e95-cfb1-449b-a986-21657cc01b22-
c000.snappy.parquet%'")
.withColumn("timestamp", f.expr("from_unixtime(add.modificationTime / 1000)"))
.select(
"filename",
"timestamp",
"add",
)
).display()and
# Check removed files
(
spark
.read
.json("s3://avinashkhamanekar/tmp/test_table_original12/_delta_log/",
pathGlobFilter="*.json")
.withColumn("filename", f.input_file_name())
.where("remove.path LIKE '%part-00000-36ee2e95-cfb1-449b-a986-21657cc01b22-
c000.snappy.parquet%'")
.withColumn("timestamp", f.expr("from_unixtime(remove.deletionTimestamp / 1000)"))
.select(
"filename",
"timestamp",
"remove"
)
).display()
Best regards,
Raphael Balogo
Sr. Technical Solutions Engineer
Databricks
Raphael Balogo
Sr. Technical Solutions Engineer
Databricks