Can anybody suggest what I must do on my database to resolve this issue.
I am running the code below:
SELECT O.ClientOrderNr Orders,COUNT(*) Records
FROM tbItem I WITH (nolock)
INNER JOIN tbProductionOrder PO WITH (nolock)
ON I.POID = Po.POID
AND I.ProductID = PO.ProductID
INNER JOIN tbOrder O WITH (nolock)
ON PO.OrderID = O.OrderID
WHERE I.ClientID = 1610
GROUP BY O.ClientOrderNr
ORDER BY O.ClientOrderNr
and it flags the following error:
Msg 601, Level 12, State 1, Line 1
Could not continue scan with NOLOCK due to data movement.
I removed WITH (nolock)
Msg 845, Level 17, State 1, Line 1
Time-out occurred while waiting for buffer latch type 2 for page (3:145369), database ID 5.
I have also ran to situation that someone suggested I/O device error, on this I run scandisk on my server that eventually corrupt the disk, I restore backup of the database but unfortunately this has not help me in any form
Presently I have a bout 1.2 billion record on one of the tables
Can anybody describe how I can horizontally partition the database