Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 SQL Server Development (2000)
 finding an object id

Author  Topic 

lauramayer
Posting Yak Master

152 Posts

Posted - 2004-06-03 : 07:53:16
Good morning,

We have a problem with one of our databases. When I run dbcc checkdb it gives me an error and and an objectID of the table. How do I find the name of that table from the object id?

Thanks so much

Laura

RickD
Slow But Sure Yak Herding Master

3608 Posts

Posted - 2004-06-03 : 07:59:33
select name from sysobjects where id = @Yourid
Go to Top of Page

derrickleggett
Pointy Haired Yak DBA

4184 Posts

Posted - 2004-06-03 : 08:04:55
or SELECT OBJECT_NAME(@Yourid)

MeanOldDBA
derrickleggett@hotmail.com

When life gives you a lemon, fire the DBA.
Go to Top of Page

lauramayer
Posting Yak Master

152 Posts

Posted - 2004-06-03 : 08:14:35
Excellent. Found it now is it possible to find the page? It says "Table error: Object ID 130099504, index ID 1. The high key value on page (1:1585) (level 0) is not less than the low key value in the parent (0:1), slot 0 of the next page (1:61456)." There are more errors this is just one of them

Or am I asking way to much and just shut up and do a dbcc checktable ('tblTrailerRouteHistory', repair_rebuild)?

Thanks

Laura
Go to Top of Page
   

- Advertisement -