相关疑难解决方法(0)

向表添加页面压缩是否也会压缩现有索引?

我正在创建一系列将启用页面级压缩的新表。

这是否也会影响索引,还是在创建索引时我还必须指定压缩?

create table Message
(
  pk_Message   int identity  NOT NULL constraint PK_Message primary key,
  [Message]    varchar(900)  NOT NULL constraint UK_Message__Message unique,
  DateCreated  datetime      NOT NULL default getdate()
) with (data_compression = page)
go  
Run Code Online (Sandbox Code Playgroud)

正如您在我的示例中看到的那样,我计划对相当大的数据类型创建唯一约束,并希望利用压缩。

sql-server sql-server-2008-r2 compression

3
推荐指数
1
解决办法
3614
查看次数