Friends,
In last post post #54 we understood what is a Heap table. Now the challenge is what if this table is highly fragmented so.
Now our task is to run maintenance of this highly fragmented table.
So you have to run following command
“ALTER TABLE TABLENAME REBUILD;
For example I run the Rebuild for Adventureworks2012 database’s heap table which we found in post #54.
See below snap for detail
So, with this REBUILD command the table is rebuild and the fragmentation issue resolved.
I hope it may help you some where.
Thanks & Enjoy!!!
RJ!!