sql-server-maintenance-solution icon indicating copy to clipboard operation
sql-server-maintenance-solution copied to clipboard

The multi-part identifier "partitions.partition_number" could not be bound.

Open zikato opened this issue 4 years ago • 1 comments

Description of the issue In the section -- Select indexes in the current database:

When partition level is set to 'N' and @Version is > 14 the dynamic sql won't join sys.partitions but tries to use it in a join with index_resumable_operations

SQL Server version and edition Microsoft SQL Server 2017 (RTM-CU16) (KB4508218) - 14.0.3223.3 (X64) Jul 12 2019 17:43:08 Copyright (C) 2017 Microsoft Corporation Enterprise Edition: Core-based Licensing (64-bit) on Windows Server 2019 Standard 10.0 <X64> (Build 17763: )

Version of the script Version: 2019-01-01 19:33:57 I think also 2020-01-26 14:06:53

What command are you executing? EXEC dbo.IndexOptimize @FragmentationLevel1 = 10, @FragmentationLevel2 = 25, @FragmentationMedium = NULL, @UpdateStatistics = 'ALL', @OnlyModifiedStatistics = 'Y', @StatisticsSample = 100, @WaitAtLowPriorityMaxDuration = 2, @WaitAtLowPriorityAbortAfterWait = 'BLOCKERS', @MaxDOP = 12, @PartitionLevel = 'N', @SortInTempdb = 'Y', @LogToTable = 'Y'

What output are you getting? Msg 4104, Level 16, State 1, Line 18 The multi-part identifier "partitions.partition_number" could not be bound.

zikato avatar Mar 03 '20 08:03 zikato

Not sure how to upvote this issue but I am also seeing this behaviour. SQL Build: 14.0.3430.2 IndexOptimize Version: 2022-01-02 13:58:13

Is there a fix or workaround?

NFryGH avatar Aug 25 '22 07:08 NFryGH