免费注册 查看新帖 |

Chinaunix

  平台 论坛 博客 文库
最近访问板块 发新帖
查看: 1615 | 回复: 3
打印 上一主题 下一主题

求教关于ignore_dup_row的设置 [复制链接]

论坛徽章:
0
跳转到指定楼层
1 [收藏(0)] [报告]
发表于 2003-08-08 09:24 |只看该作者 |倒序浏览
在create index的时候这样
create clustered index pppp_index1 on pppp(col1) with ignore_dup_row
但是在创建之后sp_help pppp得到的是这样的结果: pppp_index1          clustered, allow duplicate rows located on default
          col1
而且可以插入重复行,这是怎么回事?

论坛徽章:
0
2 [报告]
发表于 2003-08-08 09:47 |只看该作者

求教关于ignore_dup_row的设置

create table test_1 (col1  char(8) not null ,col2 int  not null , col3 smalldatetime  null)

create clustered index index1 on test_1(col1) with ignore_dup_row
sp_help test_1


index_name           index_description                                        index_keys                                                                                                                                          index_max_rows_per_page index_fillfactor index_reservepagegap index_created      
----------           -----------------                                        ----------                                ----------------------- ---------------- -------------------- -------------      
index1               clustered, ignore duplicate rows located on default       col1                                                                                                                                                                                                                                                                                 0                0                    0 Aug  8 2003  9:49AM



不会把?

论坛徽章:
0
3 [报告]
发表于 2003-08-08 14:31 |只看该作者

求教关于ignore_dup_row的设置

按照您的脚本一字不差进行操作,在create index的时候提示Warning: Clustered index 'index1' has been created with ignore_dup_row on table 'test_1', which uses data-only locking. ignore_dup_row cannot be enforced for subsequent insertions and updates.

但是在sp_help test_1时
仍然:
index1               clustered, allow duplicate rows located on default
          col1
我怀疑是不是与版本有关??

论坛徽章:
0
4 [报告]
发表于 2003-08-08 15:16 |只看该作者

求教关于ignore_dup_row的设置

按照您的脚本一字不差进行操作,在create index的时候提示Warning: Clustered index 'index1' has been created with ignore_dup_row on table 'test_1', which uses data-only locking. ignore_dup_row cannot be enforced for subsequent insertions and updates.

但是在sp_help test_1时
仍然:
index1 clustered, allow duplicate rows located on default
col1
我怀疑是不是与版本有关??

---------------------------------------------------------------------------------
哈哈  你的表建立时缺省 为 DOL 表 我建立时为 APL 表这个是唯一差别!!


在建表的脚本最后 加 LOCK ALLPAGES 重新看看!!     
create table test_1 (col1 char( not null ,col2 int not null , col3 smalldatetime null)  LOCK ALLPAGES

go
您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

北京盛拓优讯信息技术有限公司. 版权所有 京ICP备16024965号-6 北京市公安局海淀分局网监中心备案编号:11010802020122 niuxiaotong@pcpop.com 17352615567
未成年举报专区
中国互联网协会会员  联系我们:huangweiwei@itpub.net
感谢所有关心和支持过ChinaUnix的朋友们 转载本站内容请注明原作者名及出处

清除 Cookies - ChinaUnix - Archiver - WAP - TOP