sp_whoisactive
resulting an unknown query:
insert into <table_name> select *,%%bmk%% from <table_name> option (maxdop 1)
I have checked the above code block but did not find this code in any of my procedures. Can anyone please suggest what this query might be doing.
sp_whoisactive is not a built in SQL Server procedure.
It is a UPD (Used defined Procedure).
Check the procedures on your database or master / msdb
This is a clustered index being rebuilt.
%BMK% is the function that maps the old bookmarks to the new.
There is a document here that discusses the process: https://technet.microsoft.com/en-in/library/cc966402(en-us).aspx