cancel
Showing results for 
Search instead for 
Did you mean: 

question on dbcc message

Former Member
0 Kudos

I am running dbcc checkdb and got following message for 2 tables:

Checking mytab1: Logical pagesize is 2048 bytes  ---long time

Checking mytab1: Logical pagesize is 2048 bytes

The total number of data pages in this table is 390.

The total number of pages which could be garbage collected to free up some space is 336.

The total number of deleted rows in the table is 3.

The total number of pages with more than 50 percent insert free space is 6.

Table has 2580 data rows.

Checking mytab2: Logical pagesize is 2048 bytes

The total number of data pages in this table is 82265.

The total number of pages which could be garbage collected to free up some space is 5431.

The total number of deleted rows in the table is 763.

They are small table, but dbcc took long time on it. Does it mean something wrong with these 2 tables?

How to figure out and resolve the problem if any?

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Well, in the first table, there are 390 pages, 84% have data that can be cleaned up (think pointers to indexes and data).

The second table only has about 7% with data to be cleaned up, which isn't low, but not particularly high either.  I'm not so sure why you would have issues there.

I would suggest you try running a reorg rebuild on both tables, and then see how long the dbcc takes.

Answers (1)

Answers (1)

Former Member
0 Kudos

From your post, did not see any error with dbcc checkdb. So you do not need to fix any dbcc error.
For the fragmentation, you may run reorg rebuild to the 2 tables.

-- step 1 reorg rebuild with proper syntax
-- according to the menu online for ASE 12.5. reorg rebuild can be used only on data-only-locked tables.
-- sp_help mytab to find out lock schema
reorg rebuild mytab
go

-- step 2 dbcc checktable
select getdate()
go
dbcc checktable (mytab) -- check table not the entire db
go
select getdate()
go

mytab1: 390 pages (for 2k pagesize=780kb)
mytab2: 82265 pages (for 2k pagesize=165430kb)
mytab2 should take longer.

Regards,