tigertoolbox icon indicating copy to clipboard operation
tigertoolbox copied to clipboard

AdaptiveIndexDefrag only works on index_id = 1?

Open SvenAelterman opened this issue 6 years ago • 0 comments

I am just trying out the AdaptiveIndexDefrag. On two tables, I had significant fragmentation (exceeding well over 30%) in the primary key, but also on other indexes.

After running AdaptiveIndexDefrag (multiple times), the fragmentation of the PK in one table is 0, on the other it's still 50. However, none of the other indexes were touched.

I've tried several different options, the latest one this:

EXEC [dbo].[usp_AdaptiveIndexDefrag] @dbScope = 'mydb', @printCmds = 1
    , @onlineRebuild = 1, @statsSample = 'FULLSCAN'

PS: This is on an Azure SQL DB.

SvenAelterman avatar Oct 18 '19 15:10 SvenAelterman