转至繁体中文版     | 网站首页 | 图文教程 | 资源下载 | 站长博客 | 图片素材 | 武汉seo | 武汉网站优化 | 
最新公告:     敏韬网|教学资源学习资料永久免费分享站!  [mintao  2008年9月2日]        
您现在的位置: 学习笔记 >> 图文教程 >> 数据库 >> SyBase >> 正文
各位老大,问个问题         ★★★★

各位老大,问个问题

作者:闵涛 文章来源:闵涛的学习笔记 点击数:758 更新时间:2009/4/22 23:09:39

Msg 9996, Level 16, State 1:
Line 1:
Keys of index id 3 for table 'LSHSPZ' in index page not in proper order. Drop
and recreate the index. (index page 13712)
Msg 806, Level 16, State 1:
Line 1:
Could not find virtual page for logical page 14499072  in database 'cwbase1'.
DBCC execution completed. If DBCC printed error messages, contact a user with
System Administrator (SA) role.

怎么解决,谢谢

 1017of 回复于:2005-07-22 12:37:57 数据一致性问题

 windsand 回复于:2005-07-22 12:43:10 我对删除索引和重建索引不熟

 cisco2511 回复于:2005-07-22 20:49:38 对数据库做DBCC,检查一下数据库

 windsand 回复于:2005-07-23 12:22:58 故障:无法保存银行凭证
显示:
     fatal error  806
测试查找原因
1、 数据库核查
    use master
go
sp_dboption cwbase1,"single user",true
go
use cwbase1
go
checkpoint
go
dbcc checkdb(cwbase1)
go
dbcc checkalloc(cwbase1,fix)
go
dbcc checkcatalog(cwbase1)
go
use master
go
sp_dboption cwbase1,"single user",false
go
use cwbase1
go
checkpoint
go
quit
go

显示
  Database option 'single user' turned ON for database 'cwbase1'.
Run the CHECKPOINT command in the database that was changed.
(return status = 0) 
Checking cwbase1
Checking sysobjects
…………………………….
……………………………
virtual start addr      size      segments
--------------------    ------    --------------------------
67108864                       1024000
                               0
                               1
83886080                       256000
                                    2
DBCC execution completed. If DBCC printed error messages, contact a user with
System Administrator (SA) role.
Database option 'single user' turned OFF for database 'cwbase1'.
Run the CHECKPOINT command in the database that was changed.
(return status = 0)
  如111out

2、 表检查
  use cwbase1
go
dbcc checktable(LSHSPZ)
go
dbcc tablealloc(LSHSPZ)
GO
 显示:
   Checking LSHSPZ
The total number of data pages in this table is 1149.
The total number of pages which could be garbage collected to free up some space
is 207.
Table has 8326 data rows.
Msg 9996, Level 16, State 1:
Line 1:
Keys of index id 3 for table 'LSHSPZ' in index page not in proper order. Drop
and recreate the index. (index page 13712)
Msg 806, Level 16, State 1:
Line 1:
Could not find virtual page for logical page 14499072  in database 'cwbase1'.
DBCC execution completed. If DBCC printed error messages, contact a user with
System Administrator (SA) role.
The default report option of OPTIMIZED is used for this run.
The default fix option of FIX   is used for this run.
***************************************************************
TABLE: LSHSPZ OBJID = 1457440266
INDID=0  FIRST=11201  ROOT=11201  SORT=0
Data level: 0.  1149 Data pages allocated and 149 Extents allocated.
INDID=2  FIRST=11249  ROOT=11248  SORT=1
Indid   : 2.  75 Index pages allocated and 10 Extents allocated.
INDID=3  FIRST=13713  ROOT=13712  SORT=1
Indid   : 3.  62 Index pages allocated and 9 Extents allocated.
INDID=4  FIRST=13729  ROOT=13728  SORT=1
Indid   : 4.  49 Index pages allocated and 7 Extents allocated.
INDID=5  FIRST=11233  ROOT=11232  SORT=0
Indid   : 5.  262 Index pages allocated and 35 Extents allocated.
TOTAL # of extents = 210
Alloc page 11008 (# of extent=1 used pages=8 ref pages=8)
Alloc page 41472 (# of extent=1 used pages=8 ref pages=8)
Alloc page 41728 (# of extent=5 used pages=40 ref pages=40)
Alloc page 42240 (# of extent=1 used pages=8 ref pages=8)
。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。
。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。
Alloc page 49664 (# of extent=2 used pages=16 ref pages=16)
Alloc page 58368 (# of extent=1 used pages=8 ref pages=8)
Alloc page 59904 (# of extent=1 used pages=3 ref pages=3)
Alloc page 60160 (# of extent=1 used pages=2 ref pages=2)
Total (# of extent=210 used pages=1611 ref pages=1611) in this database
DBCC execution completed. If DBCC printed error messages, contact a user with
System Administrator (SA) role.

3、 解决故障
1> sp_helpindex LSHSPZ
2> go
3> drop index LSHSPZ.LSHSPZ1
4> go
5> CREATE nonclustered INDEX LSHSPZ1 ON LSHSPZ(F_DATE)
6> go
7> drop index LSHSPZ.LSHSPZ2
8> go
9> CREATE nonclustered INDEX LSHSPZ2 ON LSHSPZ(F_PZBH)
10> Go
11> drop index LSHSPZ.LSHSPZ3
12> go
13> CREATE nonclustered INDEX LSHSPZ3 ON LSHSPZ(F_KMBH)
14> Go
15> drop index LSHSPZ.LSHSPZ
16> go
17> CREATE unique clustered INDEX LSHSPZ ON LSHSPZ(F_DATE, F_PZBH, F_FLBH, F_FZBH, F_HSBH)
18> Go

 hobbylu 回复于:2005-07-23 19:24:12 写的不错,很完整一个流程

 onlywxw 回复于:2005-07-24 20:20:50 哈哈,重建一个索引要这么复杂的过程吗?不过楼主的严谨做法确实令人敬佩,也值得学习和提倡

关闭本页  


没有相关教程
教程录入:mintao    责任编辑:mintao 
  • 上一篇教程:

  • 下一篇教程:
  • 【字体: 】【发表评论】【加入收藏】【告诉好友】【打印此文】【关闭窗口
      注:本站部分文章源于互联网,版权归原作者所有!如有侵权,请原作者与本站联系,本站将立即删除! 本站文章除特别注明外均可转载,但需注明出处! [MinTao学以致用网]
      网友评论:(只显示最新10条。评论内容只代表网友观点,与本站立场无关!)

    同类栏目
    · Sql Server  · MySql
    · Access  · ORACLE
    · SyBase  · 其他
    更多内容
    热门推荐 更多内容
  • 没有教程
  • 赞助链接
    更多内容
    闵涛博文 更多关于武汉SEO的内容
    500 - 内部服务器错误。

    500 - 内部服务器错误。

    您查找的资源存在问题,因而无法显示。

    | 设为首页 |加入收藏 | 联系站长 | 友情链接 | 版权申明 | 广告服务
    MinTao学以致用网

    Copyright @ 2007-2012 敏韬网(敏而好学,文韬武略--MinTao.Net)(学习笔记) Inc All Rights Reserved.
    闵涛 投放广告、内容合作请Q我! E_mail:admin@mintao.net(欢迎提供学习资源)

    站长:MinTao ICP备案号:鄂ICP备11006601号-18

    闵涛站盟:医药大全-武穴网A打造BCD……
    咸宁网络警察报警平台