data compression

  • Hi Friends,

    We are to compress data in Sql server 2000, 2005 and 2008.

    We are using Standard edition and so we could not use the Vardecimal concept for the data compression.

    Could any one suggest a common compression technique which works in all sql server 2000,2005 and 2008.

    Note : we use

    create table cmprs_test compress

    as select * from parent_i

    in oracle to accomplish data compression in oracle.

    Could we have something similar in sql server.

    Thanks.

  • With that Oracle example you are creating a new table from an existing table. The outcome may be that the new table uses less space than the existing table due to the way it can write to the blocks but it is not compression. Is that what you want to do in SQL Server or actual compression of the data?

  • akila.baskaran (5/18/2009)


    Could any one suggest a common compression technique which works in all sql server 2000,2005 and 2008.

    There isn't one.

    SQL 2005 (from SP2 onwards) has vardecimal, SQL 2008 has row and page compression, but there's no compression at all in SQL 2000.

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass
  • I don't know of, nor have I heard of any mechanisms for data compression prior to SQL Server 2008. You can get third party software that will compress backups for SQL Server 2000 & 2005, but not data.

    "The credit belongs to the man who is actually in the arena, whose face is marred by dust and sweat and blood"
    - Theodore Roosevelt

    Author of:
    SQL Server Execution Plans
    SQL Server Query Performance Tuning

  • hi,

    Any way either reducing the data size or the table size should be fine.

  • hi,

    Any way either reducing the data size or the table size should be fine.

  • You can reorganize the database using a maintenance plan or by shrinking the database in Enterprise Manager/Management Studio. This will do the equivalent of what you are doing in Oracle (ie: utilise more of the space in the blocks in which the data resides) but against the entire database. Actual data compression is only available in SQL 2008

  • DNA (5/18/2009)


    You can reorganize the database using a maintenance plan or by shrinking the database in Enterprise Manager/Management Studio.

    However note that shrinking will badly fragment all indexes and may well hinder performance. Also, next time there's any data added, the DB will grow again. That's an intensive operation and may slow things down.

    Shrink is not recommended on a production database.

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass

Viewing 8 posts - 1 through 8 (of 8 total)

You must be logged in to reply to this topic. Login to reply