Solved

Corrupt Table, Cant Delete, Truncate ...

Posted on 2006-07-06
9
349 Views
Last Modified: 2008-03-06
I have a SQL Server 2000 Table that seems to be corrupt.

I first noticed this when attempting to Delete all records from the table.  The operation ran for 8 min without completing.  I then tried:
Truncating
Drop Table
Delete using EM Console

All of these operations will run for several minutes without completing.  I have a current backup of that table that works fine, but I need to get rid of the current one first.  I have never encountered this issue before.  Can someone lend a hand.
Thanks,
0
Comment
Question by:BillPowell
  • 3
  • 3
  • 2
  • +1
9 Comments
 
LVL 27

Expert Comment

by:ptjcb
Comment Utility
Are you sure it is corrupt?  Are other users using the table that you are trying to delete?
0
 
LVL 11

Author Comment

by:BillPowell
Comment Utility
Im pretty sure no one else is using it.  I should also mention that I cannot even perform selects againts that table.
0
 
LVL 75

Expert Comment

by:Aneesh Retnakaran
Comment Utility
run

DBCC CHECKTABLE ('urtablename')
GO
0
 
LVL 23

Assisted Solution

by:Racim BOUDJAKDJI
Racim BOUDJAKDJI earned 50 total points
Comment Utility
as ptjcb stated you need to be sure it is corrupt.  You need to find out how it is corrupted and act depending on how it would be corrupted...You may use dbcc checktable statement to find out.
0
IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

 
LVL 27

Assisted Solution

by:ptjcb
ptjcb earned 100 total points
Comment Utility
Ok...sp_who2  or check the activity monitor.

see if anyone else is using the table. Check for exclusive locks, etc. You may be blocking yourself if you have several processes trying to do the same thing.
0
 
LVL 11

Author Comment

by:BillPowell
Comment Utility
Your right.  Its not corrupt.  Theres a previous process running.  Its my process, so using KILL wont work to stop it.  How do I stop it.
0
 
LVL 75

Accepted Solution

by:
Aneesh Retnakaran earned 250 total points
Comment Utility
Close  that Query analyzer window ...

or try to kill from another QA
0
 
LVL 27

Expert Comment

by:ptjcb
Comment Utility
If this is a process outside of SQL (extended procedure, etc) then SQL Server will not kill it with a KILL command. It runs in the memory space but SQL has no control over it. You will have to stop and start the SQL Server service to kill it.
0
 
LVL 11

Author Comment

by:BillPowell
Comment Utility
I had to kill the process from another computer.  Not sure why it got hung up, but its fixed anyway.
Thanks
0

Featured Post

Backup Your Microsoft Windows Server®

Backup all your Microsoft Windows Server – on-premises, in remote locations, in private and hybrid clouds. Your entire Windows Server will be backed up in one easy step with patented, block-level disk imaging. We achieve RTOs (recovery time objectives) as low as 15 seconds.

Join & Write a Comment

Nowadays, some of developer are too much worried about data. Who is using data, who is updating it etc. etc. Because, data is more costlier in term of money and information. So security of data is focusing concern in days. Lets' understand the Au…
Ever wondered why sometimes your SQL Server is slow or unresponsive with connections spiking up but by the time you go in, all is well? The following article will show you how to install and configure a SQL job that will send you email alerts includ…
Using examples as well as descriptions, and references to Books Online, show the different Recovery Models available in SQL Server and explain, as well as show how full, differential and transaction log backups are performed
Via a live example, show how to set up a backup for SQL Server using a Maintenance Plan and how to schedule the job into SQL Server Agent.

763 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now