Wednesday, March 7, 2012

Freeing Space after Deleting Rows

I deleted some records that contain blob data from a table
but realized no effect to my physical disk space.
Shrinking the table and/or database returned no positive
impact. executed sp_spaceused on the table with no effect.
Should I truncate the table to release the space?
Truncate will delete all records and that's not what is
expected.
Please give me your suggestions.
Thanks...
Stokowhat do you mean when you say 'physical disk space'? Are you talking about
OS level space at the file system level, or space reported by SQL as being
consumed by the table. Can you list exactly what output you're looking at?
It wasn't 100% clear to me from your message...
--
Brian
"stoko" <anonymous@.discussions.microsoft.com> wrote in message
news:05cf01c3fadf$2111ede0$a401280a@.phx.gbl...
> I deleted some records that contain blob data from a table
> but realized no effect to my physical disk space.
> Shrinking the table and/or database returned no positive
> impact. executed sp_spaceused on the table with no effect.
> Should I truncate the table to release the space?
> Truncate will delete all records and that's not what is
> expected.
> Please give me your suggestions.
> Thanks...
> Stoko|||I am sorry for the lack of details.
I was expecting that after deleting a blob record holding
723556kb of file, this space should be released to the os
level of my server. hence if I had 2gigs of free space, I
should now have at least 2.7 gigs. This wasn't the case --
even at sql sever level, the space is still not released.
I appreciate your immediate response.
Stoko
>--Original Message--
>what do you mean when you say 'physical disk space'? Are
you talking about
>OS level space at the file system level, or space
reported by SQL as being
>consumed by the table. Can you list exactly what output
you're looking at?
>It wasn't 100% clear to me from your message...
>--
>Brian
>
>"stoko" <anonymous@.discussions.microsoft.com> wrote in
message
>news:05cf01c3fadf$2111ede0$a401280a@.phx.gbl...
>> I deleted some records that contain blob data from a
table
>> but realized no effect to my physical disk space.
>> Shrinking the table and/or database returned no positive
>> impact. executed sp_spaceused on the table with no
effect.
>> Should I truncate the table to release the space?
>> Truncate will delete all records and that's not what is
>> expected.
>> Please give me your suggestions.
>> Thanks...
>> Stoko
>
>.
>|||take a look at dbcc shrinkfile.
Files are not shrunk as space is remove from them. This is by design since
it would create a huge performance problem...
--
Brian Moran
Principal Mentor
Solid Quality Learning
SQL Server MVP
http://www.solidqualitylearning.com
"stoko" <anonymous@.discussions.microsoft.com> wrote in message
news:079801c3fae2$f1c7ec70$a101280a@.phx.gbl...
> I am sorry for the lack of details.
> I was expecting that after deleting a blob record holding
> 723556kb of file, this space should be released to the os
> level of my server. hence if I had 2gigs of free space, I
> should now have at least 2.7 gigs. This wasn't the case --
> even at sql sever level, the space is still not released.
> I appreciate your immediate response.
> Stoko
> >--Original Message--
> >what do you mean when you say 'physical disk space'? Are
> you talking about
> >OS level space at the file system level, or space
> reported by SQL as being
> >consumed by the table. Can you list exactly what output
> you're looking at?
> >It wasn't 100% clear to me from your message...
> >
> >--
> >
> >Brian
> >
> >
> >"stoko" <anonymous@.discussions.microsoft.com> wrote in
> message
> >news:05cf01c3fadf$2111ede0$a401280a@.phx.gbl...
> >> I deleted some records that contain blob data from a
> table
> >> but realized no effect to my physical disk space.
> >> Shrinking the table and/or database returned no positive
> >> impact. executed sp_spaceused on the table with no
> effect.
> >>
> >> Should I truncate the table to release the space?
> >> Truncate will delete all records and that's not what is
> >> expected.
> >>
> >> Please give me your suggestions.
> >> Thanks...
> >> Stoko
> >
> >
> >.
> >

No comments:

Post a Comment