microsoft / tigertoolbox

Toolbox repository for Tiger team
http://aka.ms/sqlserverteam
Other
1.45k stars 734 forks source link

Executing usp_AdaptiveIndexDefrag in a Azure Data Factory (ADF) activity #270

Open cyrmul opened 2 years ago

cyrmul commented 2 years ago

Hi,

I use Azure Data Factory (ADF) in my project. I would like to extend the use of ADF to do the maintenance of the Azure SQL Database but it doesn't work.

I can execute the stored procedure usp_AdaptiveIndexDefrag in SSMS and it works very well (thanks! 👍 ). I have my pipeline with the stored procedure activity, but the execution takes only 4 seconds. It ends OK but nothing has been done: there is no row in tbl_AdaptiveIndexDefrag_log for example. With the SQL Profiler, I see the query "exec [dbo].[usp_AdaptiveIndexDefrag]" but it doesn't help me...

Do you have an idea to fix this?

ADF_index