Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
Author |
Topic |
Kimi86
Yak Posting Veteran
79 Posts |
Posted - 2013-03-01 : 11:35:54
|
I have a table with a varchar column that stores XML and consumes too much space..Hence I want to Set All XML fields to NULL and put those XMLs in another TAble. I dont want to drop the entire column since only 40 percent of the rows have XML while other have some other text stored in it.My problem Is when I set the XML fields to NULL the space occupied by the table does not change at all. I have tried DBCC CLEANTABLE but tat dint help..Also I dont want to copy the table into another table and rename it since the table is tooo heavy ..Any Idea?? |
|
James K
Master Smack Fu Yak Hacker
3873 Posts |
|
Lamprey
Master Smack Fu Yak Hacker
4614 Posts |
Posted - 2013-03-01 : 13:10:42
|
I assume you mean that the MDF file didn't shrink? If so, SQL is not going to give up any space willingly. If you want to reclaim that disk space you'll have to shrink the database (if do decide to shrink your DB, read up on how to do it properly). You might try rebuilding the indexes and see if that helps.Also after running CLEANTABLE did you run UPDATEUSAGE? |
|
|
|
|
|