Click here to Skip to main content
15,894,896 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
C#
2016-07-07 14:13:10.8460202 : Application Started ...................................................
2016-07-07 14:13:10.8519924 : Email Sending Started ..................................
2016-07-07 14:13:57.1407184 : DynECT Error:Transaction (Process ID 87) was deadlocked on lock resources with another process and has been chosen as the deadlock victim. Rerun the transaction.   at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection, Action`1 wrapCloseInAction)
   at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj, Boolean callerHasConnectionLock, Boolean asyncClose)
   at System.Data.SqlClient.TdsParser.TryRun(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj, Boolean& dataReady)
   at System.Data.SqlClient.SqlDataReader.TryConsumeMetaData()
   at System.Data.SqlClient.SqlDataReader.get_MetaData()
   at System.Data.SqlClient.SqlCommand.FinishExecuteReader(SqlDataReader ds, RunBehavior runBehavior, String resetOptionsString)
   at System.Data.SqlClient.SqlCommand.RunExecuteReaderTds(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, Boolean async, Int32 timeout, Task& task, Boolean asyncWrite, SqlDataReader ds)
   at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method, TaskCompletionSource`1 completion, Int32 timeout, Task& task, Boolean asyncWrite)
   at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method)
   at System.Data.SqlClient.SqlCommand.ExecuteReader(CommandBehavior behavior, String method)
   at System.Data.SqlClient.SqlCommand.ExecuteDbDataReader(CommandBehavior behavior)
   at System.Data.Common.DbCommand.System.Data.IDbCommand.ExecuteReader(CommandBehavior behavior)
   at System.Data.Common.DbDataAdapter.FillInternal(DataSet dataset, DataTable[] datatables, Int32 startRecord, Int32 maxRecords, String srcTable, IDbCommand command, CommandBehavior behavior)
   at System.Data.Common.DbDataAdapter.Fill(DataSet dataSet, Int32 startRecord, Int32 maxRecords, String srcTable, IDbCommand command, CommandBehavior behavior)
   at System.Data.Common.DbDataAdapter.Fill(DataSet dataSet)
   at FRSQL.DB.GetDataSet(SqlCommand myCmd)
   at FrontRushDataAccess.MessageQueueDataAccess.getMessagesQueueDynECT()
   at FrontRushEmail.Process.SendMailsDynECT(String& totalMessages, String& totalMessageinDB, String& totalTimeFromDB)
   at FrontRushEmail.Program.StartProcessForDyn(String& totalMessages, String& totalMessageinDB, String& totalTimeFromDB)
2016-07-07 14:13:57.1417186 : DynECT: "Time: 2016-07-07 14:13:57.1407184"," Total Messages in DB : 0"," Total messages to be processed :0"," Time Taken: 00:00:46.2892131"," Total Time from DB : "," Total Avg time per msg(seconds): 46.2892131", " Batch Size: 20" 
2016-07-07 14:13:57.1417186 : Application Finished ...................................................


What I have tried:

Transaction (Process ID 87) was deadlocked on lock resources with another process and has been chosen as the deadlock victim. Rerun the transaction. at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection, Action`1 wrapCloseInAction)
Posted
Updated 7-Jul-16 21:35pm

1 solution

If you don't understand an error message, Google it:
was deadlocked on lock resources with another process and has been chosen as the deadlock victim - Google Search[^]
As you can see, you aren't the first to meet this problem, and loads of possible solutions are proposed.
So follow some of the links and read what they say first: we can't tell you exactly what to do becasue we don;t have any access to your systems or data!
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900