Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Optimizing deletion in batch
Message
De
31/12/2013 13:48:26
 
 
À
31/12/2013 01:31:39
Information générale
Forum:
Microsoft SQL Server
Catégorie:
Maintenance bases de données
Versions des environnements
SQL Server:
SQL Server 2008
Application:
Web
Divers
Thread ID:
01591061
Message ID:
01591189
Vues:
53
>OK, I see.
>
>Can you post the code for the DELETE process, as well as the other block of code (assuming there's another block) that's involved in the deadlock?

This is the delete:
DECLARE @Numero Int

SET @Numero=something

DELETE FROM Hit
 WHERE Numero<@Numero
This is the other code involved in the deadlock:
DECLARE @AddUser Int
DECLARE @AddDate DateTime
DECLARE @ProcessID Int
DECLARE @Page NVarChar
DECLARE @Lap Int
DECLARE @IP NVarChar
DECLARE @QueryStrin NVarChar
DECLARE @NoServer Int
DECLARE @InputStream NVarChar
DECLARE @OutputStream NVarChar
DECLARE @Log NVarChar
DECLARE @SQLCountSQLExec Int
DECLARE @SQLCountSQLUpdate Int
DECLARE @SQLCountSQLInsert Int
DECLARE @SQLCountSQLDelete Int
DECLARE @Server NVarChar

SET @AddUser=0
SET @AddDate='2013-12-29 15:20:03'
SET @ProcessID=5776
SET @Page='default.aspx'
SET @Lap=-1
SET @IP='something'
SET @QueryStrin=''
SET @NoServer=4
SET @InputStream=''
SET @OutputStream=''
SET @Log=''
SET @SQLCountSQLExec=0
SET @SQLCountSQLUpdate=0
SET @SQLCountSQLInsert=0
SET @SQLCountSQLDelete=0
SET @Server='something'

INSERT INTO Hit (AddUser,AddDate,ProcessID,Page,Lap,IP,QueryStrin,NoServer,InputStream,OutputStream,Log,SQLCountSQLExec,SQLCountSQLUpdate,SQLCountSQLInsert,SQLCountSQLDelete,Server) VALUES (@AddUser,@AddDate,@ProcessID,@Page,@Lap,@IP,@QueryStrin,@NoServer,@InputStream,@OutputStream,@Log,@SQLCountSQLExec,@SQLCountSQLUpdate,@SQLCountSQLInsert,@SQLCountSQLDelete,@Server) 
Michel Fournier
Level Extreme Inc.
Designer, architect, owner of the Level Extreme Platform
Subscribe to the site at https://www.levelextreme.com/Home/DataEntry?Activator=55&NoStore=303
Subscription benefits https://www.levelextreme.com/Home/ViewPage?Activator=7&ID=52
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform