I'm trying to execute VACUUM in Synapse notebook, and I'm using this code:
spark.sql("SET spark.databricks.delta.retentionDurationCheck.enabled = false")
#get list of all tables
table_list = spark.sql("show tables from db").select('tableName').rdd.map(lambda x : x[0]).collect()
for table in table_list:
spark.sql("VACUUM db.`{0}`".format(table)).show()
I think it's not running properly because I still have more than 1 billion rows in raw layer for example.
The code runs successfully, but if I execute a DESCRIBE HISTORY I verify that the operation does not appear in the history.
Does anyone have similar issue/experience or have an idea if I'm configuring it correctly or if it's not supported by synapse workspace?