Results 1 to 9 of 9

Thread: Db Unused space

  1. #1
    Join Date
    May 2003
    Location
    India
    Posts
    15

    Db Unused space

    Hi,

    My database’s actual size is 3+ GB, but due to this Unused (Reserved) space it currently shows as 12+ GB and grows at a rate of 150MB per every 3 hrs.
    When I check the space usage by Individual tables, I saw a table <xxx> having reserved space of around 8 GB which contains only 2 columns of which one is an integer (primary key, clustered index) and the other is an image data type (BLOB) field.
    The image size would be some KB or to a max of 1-2MB and once it is read, it gets automatically deleted from the table.
    There are currently less than 20 rows in the table.

    Is there any way to get rid of this unused space other than deleting and recreating the table, cannot be done as it’s a prod environment (24*7).

    Any help on this is highly appreciated.

    Thanks,
    Pavan.

  2. #2
    Join Date
    Sep 2002
    Posts
    5,938
    Try rebuild clustered index then shrink db.

  3. #3
    Join Date
    May 2003
    Location
    India
    Posts
    15
    tried for no success...

  4. #4
    Join Date
    Sep 2002
    Posts
    5,938
    How did you do that? Tried shrink db file in ssms and choose 'reorganize pages before releasing unused space'?

  5. #5
    Join Date
    May 2003
    Location
    India
    Posts
    15
    Tried in the below way as well as this way
    http://www.dbforums.com/showthread.php?t=1631453.

    But not succeeded.

  6. #6
    Join Date
    Sep 2002
    Posts
    5,938
    I'll try it this way:

    1. ensure all tables have clustered indexre and build all indexes in the db,
    2. update usage for the db,
    3. shrink db or file in ssms.

  7. #7
    Join Date
    May 2003
    Location
    India
    Posts
    15
    Thanks for the reply, tried them but...

  8. #8
    Join Date
    Sep 2002
    Posts
    5,938
    Were there any open user connections on the db while you do that?

  9. #9
    Join Date
    May 2003
    Location
    India
    Posts
    15
    I am trying these options in our local restored copy(server), hope there were no sessions opened, but clearly that table was not accessed.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •