We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 79b2a00 commit c0d30fcCopy full SHA for c0d30fc
1 file changed
sp_IndexCleanup/sp_IndexCleanup.sql
@@ -1442,7 +1442,7 @@ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
1442
ce.can_compress = 0,
1443
ce.reason = ''Index contains incompatible data types''
1444
FROM #compression_eligibility AS ce
1445
- JOIN sys.indexes AS i
+ JOIN ' + QUOTENAME(@current_database_name) + N'.sys.indexes AS i
1446
ON i.object_id = ce.object_id AND i.index_id = ce.index_id
1447
WHERE ce.can_compress = 1
1448
AND i.type = 1
0 commit comments