When using EXECUTES to rebuild and exclude indexes from the defrag SP, I receive the following errors:
Msg 50000, Level 16, State 1, Procedure IndexOptimize, Line 918 The value for the parameter @Indexes is not supported.
Msg 50000, Level 16, State 1, Procedure IndexOptimize, Line 1009 The documentation is available at https://ola.hallengren.com/sql-server-index-and-statistics-maintenance.html.
As far as I know, my syntax is correct, and follows Ola's documentation to the T. Any thoughts?
Sample Code:
EXECUTE dbo.IndexOptimize
@Databases = 'SqlWorkflowInstanceStore_RBC_ITS-QA-Canada.27',
@FragmentationLow = NULL,
@FragmentationMedium = 'INDEX_REBUILD_ONLINE,INDEX_REBUILD_OFFLINE',
@FragmentationHigh = 'INDEX_REBUILD_ONLINE,INDEX_REBUILD_OFFLINE',
@FragmentationLevel1 = 5,
@FragmentationLevel2 = 30,
@Indexes = 'ALL_INDEXES, -SqlWorkflowInstanceStore_RBC_ITS-QA-Canada.27.System.Activities.DurableInstancing.InstancesTable,
-SqlWorkflowInstanceStore_RBC_ITS-QA-Canada.27.System.Activities.DurableInstancing.RunnableInstancesTable,
-SqlWorkflowInstanceStore_RBC_ITS-QA-Canada.27.System.Activities.DurableInstancing.LockOwnersTable,
-SqlWorkflowInstanceStore_RBC_ITS-QA-Canada.27.System.Activities.DurableInstancing.ServiceDeploymentsTable,
-SqlWorkflowInstanceStore_RBC_ITS-QA-Canada.27.System.Activities.DurableInstancing.InstancePromotedPropertiesTable,
-SqlWorkflowInstanceStore_RBC_ITS-QA-Canada.27.System.Activities.DurableInstancing.DefinitionIdentityTable,
-SqlWorkflowInstanceStore_RBC_ITS-QA-Canada.27.System.Activities.DurableInstancing.KeysTable,
-SqlWorkflowInstanceStore_RBC_ITS-QA-Canada.27.System.Activities.DurableInstancing.IdentityOwnerTable'