Ultimate access to all questions.
Consider a scenario where a SQL query is taking an unusually long time to execute due to a large number of small files in a Delta table. Explain how you would identify this issue and what steps you would take to resolve it. Specifically, discuss the use of optimized writes and compaction techniques.