Report Error - Deadlocked Resource

Whenever I try to run the Order Acknowledgement report for one specific sales order, it errors out with a deadlock message no matter the style. Yes, even the standard SSRS fails with the same message. Has anyone seen this before?

  Program Ice.Services.Lib.RunTask raised an unexpected exception with the following message: RunTask: An error occurred while reading from the store provider's data reader. See the inner exception for details.
  Stack Trace:
     at System.Data.Common.Internal.Materialization.Shaper`1.StoreRead()
     at System.Data.Common.Internal.Materialization.Shaper`1.SimpleEnumerator.MoveNext()
     at System.Linq.Enumerable.FirstOrDefault[TSource](IEnumerable`1 source)
     at Ice.IceDataContextExtensions.ReadCurrent[T,TContext](TContext ctx, T entity, LockHint lockHint) in C:\_Releases\ICE\3.1.500.16\Source\Framework\Epicor.System\Data\IceDataContextExtensions.cs:line 159
     at Erp.Internal.OM.SalesOrderAck.RunProcess(Int64 instanceTaskNum, String outputFileName) in C:\_Releases\ERP\UD10.1.500.16\Source\Server\Internal\OM\SalesOrderAck\SalesOrderAck.cs:line 423
     at Ice.Hosting.TaskCaller.InnerExecuteTask(IceDataContext newContext) in C:\_Releases\ICE\3.1.500.16\Source\Framework\Epicor.Ice\Hosting\TaskCaller\TaskCaller.cs:line 93
     at Ice.Hosting.TaskCaller.ExecuteTask() in C:\_Releases\ICE\3.1.500.16\Source\Framework\Epicor.Ice\Hosting\TaskCaller\TaskCaller.cs:line 54
     at Ice.Lib.RunTask.BpmFriendlyTaskLauncher.Run(String sessionIdPrefix, IceContext db, Action taskRunner) in C:\_Releases\ICE\3.1.500.16\Source\Server\Services\Lib\RunTask\BpmFriendlyTaskLauncher.cs:line 63
     at Ice.Services.Lib.RunTaskSvc.InnerRunTask(Int64 ipTaskNum, Boolean suppressTransaction) in C:\_Releases\ICE\3.1.500.16\Source\Server\Services\Lib\RunTask\RunTask.cs:line 526
  Inner Exception:
  Transaction (Process ID 571) was deadlocked on lock resources with another process and has been chosen as the deadlock victim. Rerun the transaction.
  Stack Trace:
     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.TryHasMoreRows(Boolean& moreRows)
     at System.Data.SqlClient.SqlDataReader.TryReadInternal(Boolean setTimeout, Boolean& more)
     at System.Data.SqlClient.SqlDataReader.Read()
     at System.Data.Common.Internal.Materialization.Shaper`1.StoreRead()
     at Ice.Services.Lib.RunTaskSvc.InnerRunTask(Int64 ipTaskNum, Boolean suppressTransaction) in C:\_Releases\ICE\3.1.500.16\Source\Server\Services\Lib\RunTask\RunTask.cs:line 526
     at Ice.Services.Lib.RunTaskSvcFacade.RunTask(Int64 ipTaskNum) in C:\_Releases\ICE\3.1.500.16\Source\Server\Services\Lib\RunTask\RunTaskSvcFacade.cs:line 87
     at SyncInvokeRunTask(Object , Object[] , Object[] )
     at System.ServiceModel.Dispatcher.SyncMethodInvoker.Invoke(Object instance, Object[] inputs, Object[]& outputs)
     at Epicor.Hosting.OperationBoundInvoker.InnerInvoke(Object instance, Func`2 func) in C:\_Releases\ICE\3.1.500.16\Source\Framework\Epicor.System\Hosting\OperationBoundInvoker.cs:line 59
     at Epicor.Hosting.OperationBoundInvoker.Invoke(Object instance, Func`2 func) in C:\_Releases\ICE\3.1.500.16\Source\Framework\Epicor.System\Hosting\OperationBoundInvoker.cs:line 28
     at Epicor.Hosting.Wcf.EpiOperationInvoker.Invoke(Object instance, Object[] inputs, Object[]& outputs) in C:\_Releases\ICE\3.1.500.16\Source\Framework\Epicor.System\Hosting\Wcf\EpiOperationInvoker.cs:line 23
     at System.ServiceModel.Dispatcher.DispatchOperationRuntime.InvokeBegin(MessageRpc& rpc)
     at System.ServiceModel.Dispatcher.ImmutableDispatchRuntime.ProcessMessage5(MessageRpc& rpc)
     at System.ServiceModel.Dispatcher.ImmutableDispatchRuntime.ProcessMessage11(MessageRpc& rpc)
     at System.ServiceModel.Dispatcher.MessageRpc.Process(Boolean isOperationContextSet)
     at System.ServiceModel.Dispatcher.ChannelHandler.DispatchAndReleasePump(RequestContext request, Boolean cleanThread, OperationContext currentOperationContext)
     at System.ServiceModel.Dispatcher.ChannelHandler.HandleRequest(RequestContext request, OperationContext currentOperationContext)
     at System.ServiceModel.Dispatcher.ChannelHandler.AsyncMessagePump(IAsyncResult result)
     at System.ServiceModel.Dispatcher.ChannelHandler.OnAsyncReceiveComplete(IAsyncResult result)
     at System.Runtime.Fx.AsyncThunk.UnhandledExceptionFrame(IAsyncResult result)
     at System.Runtime.AsyncResult.Complete(Boolean completedSynchronously)
     at System.ServiceModel.Channels.TransportDuplexSessionChannel.TryReceiveAsyncResult.OnReceive(IAsyncResult result)
     at System.Runtime.Fx.AsyncThunk.UnhandledExceptionFrame(IAsyncResult result)
     at System.Runtime.AsyncResult.Complete(Boolean completedSynchronously)
     at System.ServiceModel.Channels.SynchronizedMessageSource.ReceiveAsyncResult.OnReceiveComplete(Object state)
     at System.ServiceModel.Channels.SessionConnectionReader.OnAsyncReadComplete(Object state)
     at System.Runtime.Fx.AsyncThunk.UnhandledExceptionFrame(IAsyncResult result)
     at System.Net.LazyAsyncResult.Complete(IntPtr userToken)
     at System.Net.LazyAsyncResult.ProtectedInvokeCallback(Object result, IntPtr userToken)
     at System.Net.Security.NegotiateStream.ProcessFrameBody(Int32 readBytes, Byte[] buffer, Int32 offset, Int32 count, AsyncProtocolRequest asyncRequest)
     at System.Net.Security.NegotiateStream.ReadCallback(AsyncProtocolRequest asyncRequest)
     at System.Net.AsyncProtocolRequest.CompleteRequest(Int32 result)
     at System.Net.FixedSizeReader.CheckCompletionBeforeNextRead(Int32 bytes)
     at System.Net.FixedSizeReader.ReadCallback(IAsyncResult transportResult)
     at System.Runtime.AsyncResult.Complete(Boolean completedSynchronously)
     at System.ServiceModel.Channels.ConnectionStream.IOAsyncResult.OnAsyncIOComplete(Object state)
     at System.Net.Sockets.SocketAsyncEventArgs.OnCompleted(SocketAsyncEventArgs e)
     at System.Net.Sockets.SocketAsyncEventArgs.FinishOperationSuccess(SocketError socketError, Int32 bytesTransferred, SocketFlags flags)
     at System.Net.Sockets.SocketAsyncEventArgs.CompletionPortCallback(UInt32 errorCode, UInt32 numBytes, NativeOverlapped* nativeOverlapped)
     at System.Threading._IOCompletionCallback.PerformIOCompletionCallback(UInt32 errorCode, UInt32 numBytes, NativeOverlapped* pOVERLAP)

Actually, it turns out I cannot even alter the sales order. It comes up with the same error message.

Taken from application Help

So, I followed some of those guides and it identified that I have deadlocking, but I already knew that. What do I do with this information?

  Job 'LocksLogger' : Step 1, 'RunSPLock3' : Began Executing 2018-05-08 13:36:57

  Status Mode     Type Resource         ObjectName                     IndexName            PID      SPID   MachineName     LoginName                 DBName          ObjectID        CurrentDate                                            WaitTime   WaitResource                            
  ------ -------- ---- ---------------- ------------------------------ -------------------- -------- ------ --------------- ------------------------- --------------- --------------- ------------------------------------------------------ ---------- ----------------------------------------
  GRANT  IS       TAB                   OrderDtl                       (null)                        29                     sa                        Live            845310867       2018-05-08 13:36:57.833                                189776     KEY: 14:72057595469037568 (b27184e98d60)
  GRANT  IS       TAB                   fulltext_index_docidstatus_845 (null)                        29                     sa                        Live            1814752201      2018-05-08 13:36:57.833                                189776     KEY: 14:72057595469037568 (b27184e98d60)
  GRANT  IX       TAB                   fulltext_index_docidmap_845310 (null)                        29                     sa                        Live            1798752144      2018-05-08 13:36:57.833                                189776     KEY: 14:72057595469037568 (b27184e98d60)
  GRANT  IX       TAB                   fulltext_avdl_845310867        (null)                        29                     sa                        Live            1862752372      2018-05-08 13:36:57.833                                189776     KEY: 14:72057595469037568 (b27184e98d60)
  WAIT   S        KEY  (b27184e98d60)   fulltext_index_docidstatus_845 i3                            29                     sa                        Live            1814752201      2018-05-08 13:36:57.833                                189776     KEY: 14:72057595469037568 (b27184e98d60)
  GRANT  IS       PAG  1:2630368        fulltext_index_docidstatus_845 i3                            29                     sa                        Live            1814752201      2018-05-08 13:36:57.833                                189776     KEY: 14:72057595469037568 (b27184e98d60)
  GRANT  X        KEY  (b27184e98d60)   fulltext_index_docidstatus_845 i3                   191172   69     ISIEPICOR       E10                       Live            1814752201      2018-05-08 13:36:57.833                                0

I opened a support case, so you may get this anyways, but this seems like your cup of tea @aidacra.

restart all of the things, in this order

  1. SQL server engine
  2. application pool (appserver)
  3. task agent configuration

still get a deadlock?

Will this kick users out?

Try just restarting the Task Agent first via services.msc. Of course restarting SQL Server, App Pool would kick users out =)

No luck, Haso. Looks like I will have to wait until Sunday to try this out.

If you go to your SQL Server where your DATA is located there should be a Logs folder with an β€œERRORLOG” text file, do you have any deadlock details in there.

There is, but I’m not sure what to do with the information:

  2018-05-08 14:21:15.75 spid28s     deadlock-list
  2018-05-08 14:21:15.75 spid28s      deadlock victim=process9d6486cf8
  2018-05-08 14:21:15.75 spid28s       process-list
  2018-05-08 14:21:15.75 spid28s        process id=process9d6486cf8 taskpriority=0 logused=0 waitresource=KEY: 14:72057733317984256 (14ed0a7e2d9f) waittime=4347 ownerId=879298123 transactionname=user_transaction lasttranstarted=2018-05-08T14:21:11.400 XDES=0x1180f5d6a8 lockMode=U schedulerid=5 kpid=43248 status=suspended spid=503 sbid=2 ecid=0 priority=0 trancount=1 lastbatchstarted=2018-05-08T14:21:11.400 lastbatchcompleted=2018-05-08T14:21:11.400 lastattention=1900-01-01T00:00:00.400 clientapp=.Net SqlClient Data Provider hostname=ISIEPICOR hostpid=191172 loginname=E10 isolationlevel=read committed (2) xactid=879298123 currentdb=14 lockTimeout=180000 clientoption1=671088672 clientoption2=128056
  2018-05-08 14:21:15.75 spid28s         executionStack
  2018-05-08 14:21:15.75 spid28s          frame procname=adhoc line=1 stmtstart=60 sqlhandle=0x02000000be9eab0f9c732486d11621d40c38bbbe3e0c4a470000000000000000000000000000000000000000
  2018-05-08 14:21:15.75 spid28s     SELECT TOP (1) 
  2018-05-08 14:21:15.75 spid28s     [Extent2].[OpenOrder] AS [OpenOrder], 
  2018-05-08 14:21:15.75 spid28s     [Extent2].[VoidOrder] AS [VoidOrder], 
  2018-05-08 14:21:15.75 spid28s     [Extent2].[Company] AS [Company], 
  2018-05-08 14:21:15.75 spid28s     [Extent2].[OrderNum] AS [OrderNum], 
  2018-05-08 14:21:15.75 spid28s     [Extent2].[CustNum] AS [CustNum], 
  2018-05-08 14:21:15.75 spid28s     [Extent2].[PONum] AS [PONum], 
  2018-05-08 14:21:15.75 spid28s     [Extent2].[OrderHeld] AS [OrderHeld], 
  2018-05-08 14:21:15.75 spid28s     [Extent2].[EntryPerson] AS [EntryPerson], 
  2018-05-08 14:21:15.75 spid28s     [Extent2].[ShipToNum] AS [ShipToNum], 
  2018-05-08 14:21:15.75 spid28s     [Extent2].[RequestDate] AS [RequestDate], 
  2018-05-08 14:21:15.75 spid28s     [Extent2].[OrderDate] AS [OrderDate], 
  2018-05-08 14:21:15.75 spid28s     [Extent2].[FOB] AS [FOB], 
  2018-05-08 14:21:15.75 spid28s     [Extent2].[ShipViaCode] AS [ShipViaCode], 
  2018-05-08 14:21:15.75 spid28s     [Extent2].[TermsCode] AS [TermsCode], 
  2018-05-08 14:21:15.75 spid28s     [Extent2].[DiscountPercent] AS [DiscountPercent], 
  2018-05-08 14:21:15.75 spid28s     [Extent2].[PrcConNum] AS [PrcConNum], 
  2018-05-08 14:21:15.75 spid28s     [Extent2].[ShpConNum] AS [ShpConNum], 
  2018-05-08 14:21:15.75 spid28s     [Extent2].[SalesRepList] AS [SalesRepList], 
  2018-05-08 14:21:15.75 spid28s     [Extent2].[OrderComment] AS [OrderComment], 
  2018-05-08 14:21:15.75 spid28s     [Extent2].[ShipComment] AS [ShipComment], 
  2018-05-08 14:21:15.75 spid28s     [Extent2].[InvoiceComment] AS [InvoiceComment], 
  2018-05-08 14:21:15.75 spid28s     [Extent2].[PickListComment] AS [PickListComment], 
  2018-05-08 14:21:15.75 spid28s     [Extent2].[DepositBal] AS [DepositBal], 
  2018-05-08 14:21:15.75 spid28s     [Extent2].[DocDepositBal] AS [DocDepositBal], 
  2018-05-08 14:21:15.75 spid28s     [Exte     
  2018-05-08 14:21:15.75 spid28s          frame procname=unknown line=1 sqlhandle=0x0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
  2018-05-08 14:21:15.75 spid28s     unknown     
  2018-05-08 14:21:15.75 spid28s         inputbuf
  2018-05-08 14:21:15.75 spid28s     (@p__linq__0 uniqueidentifier)SELECT TOP (1) 
  2018-05-08 14:21:15.75 spid28s     [Extent2].[OpenOrder] AS [OpenOrder], 
  2018-05-08 14:21:15.75 spid28s     [Extent2].[VoidOrder] AS [VoidOrder], 
  2018-05-08 14:21:15.75 spid28s     [Extent2].[Company] AS [Company], 
  2018-05-08 14:21:15.75 spid28s     [Extent2].[OrderNum] AS [OrderNum], 
  2018-05-08 14:21:15.75 spid28s     [Extent2].[CustNum] AS [CustNum], 
  2018-05-08 14:21:15.75 spid28s     [Extent2].[PONum] AS [PONum], 
  2018-05-08 14:21:15.75 spid28s     [Extent2].[OrderHeld] AS [OrderHeld], 
  2018-05-08 14:21:15.75 spid28s     [Extent2].[EntryPerson] AS [EntryPerson], 
  2018-05-08 14:21:15.75 spid28s     [Extent2].[ShipToNum] AS [ShipToNum], 
  2018-05-08 14:21:15.75 spid28s     [Extent2].[RequestDate] AS [RequestDate], 
  2018-05-08 14:21:15.75 spid28s     [Extent2].[OrderDate] AS [OrderDate], 
  2018-05-08 14:21:15.75 spid28s     [Extent2].[FOB] AS [FOB], 
  2018-05-08 14:21:15.75 spid28s     [Extent2].[ShipViaCode] AS [ShipViaCode], 
  2018-05-08 14:21:15.75 spid28s     [Extent2].[TermsCode] AS [TermsCode], 
  2018-05-08 14:21:15.75 spid28s     [Extent2].[DiscountPercent] AS [DiscountPercent], 
  2018-05-08 14:21:15.75 spid28s     [Extent2].[PrcConNum] AS [PrcConNum], 
  2018-05-08 14:21:15.75 spid28s     [Extent2].[ShpConNum] AS [ShpConNum], 
  2018-05-08 14:21:15.75 spid28s     [Extent2].[SalesRepList] AS [SalesRepList], 
  2018-05-08 14:21:15.75 spid28s     [Extent2].[OrderComment] AS [OrderComment], 
  2018-05-08 14:21:15.75 spid28s     [Extent2].[ShipComment] AS [ShipComment], 
  2018-05-08 14:21:15.75 spid28s     [Extent2].[InvoiceComment] AS [InvoiceComment], 
  2018-05-08 14:21:15.75 spid28s     [Extent2].[PickListComment] AS [PickListComment], 
  2018-05-08 14:21:15.75 spid28s     [Extent2].[DepositBal] AS [DepositBal], 
  2018-05-08 14:21:15.75 spid28s     [Extent2].[DocDepositB    
  2018-05-08 14:21:15.75 spid28s        process id=processa41673c38 taskpriority=0 logused=1426440 waitresource=KEY: 14:72057733317918720 (f4c02050fd3c) waittime=3993 ownerId=879115616 transactionname=user_transaction lasttranstarted=2018-05-08T14:16:57.650 XDES=0x127545cd28 lockMode=U schedulerid=3 kpid=58992 status=suspended spid=69 sbid=2 ecid=0 priority=0 trancount=2 lastbatchstarted=2018-05-08T14:21:11.757 lastbatchcompleted=2018-05-08T14:21:11.750 lastattention=2018-05-08T07:40:55.330 clientapp=.Net SqlClient Data Provider hostname=ISIEPICOR hostpid=191172 loginname=E10 isolationlevel=read committed (2) xactid=879115616 currentdb=14 lockTimeout=180000 clientoption1=671088672 clientoption2=128056
  2018-05-08 14:21:15.75 spid28s         executionStack
  2018-05-08 14:21:15.75 spid28s          frame procname=adhoc line=1 stmtstart=110 stmtend=290 sqlhandle=0x02000000aeb41125a834a0e952ac9ca7a5cfda6b4c6727ce0000000000000000000000000000000000000000
  2018-05-08 14:21:15.75 spid28s     update [Erp].[OrderHed]
  2018-05-08 14:21:15.75 spid28s     set [TotalTax] = @0, [DocTotalTax] = @1
  2018-05-08 14:21:15.75 spid28s     where ([SysRowID] = @2)     
  2018-05-08 14:21:15.75 spid28s          frame procname=unknown line=1 sqlhandle=0x0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
  2018-05-08 14:21:15.75 spid28s     unknown     
  2018-05-08 14:21:15.75 spid28s         inputbuf
  2018-05-08 14:21:15.75 spid28s     (@0 decimal(17,3),@1 decimal(17,3),@2 uniqueidentifier)update [Erp].[OrderHed]
  2018-05-08 14:21:15.75 spid28s     set [TotalTax] = @0, [DocTotalTax] = @1
  2018-05-08 14:21:15.75 spid28s     where ([SysRowID] = @2)
  2018-05-08 14:21:15.75 spid28s     select [SysRevID]
  2018-05-08 14:21:15.75 spid28s     from [Erp].[OrderHed]
  2018-05-08 14:21:15.75 spid28s     where @@ROWCOUNT > 0 and [SysRowID] = @2    
  2018-05-08 14:21:15.75 spid28s       resource-list
  2018-05-08 14:21:15.75 spid28s        keylock hobtid=72057733317984256 dbid=14 objectname=Live.Erp.OrderHed indexname=PK_OrderHed id=lock111086c880 mode=X associatedObjectId=72057733317984256
  2018-05-08 14:21:15.75 spid28s         owner-list
  2018-05-08 14:21:15.75 spid28s          owner id=processa41673c38 mode=X
  2018-05-08 14:21:15.75 spid28s         waiter-list
  2018-05-08 14:21:15.75 spid28s          waiter id=process9d6486cf8 mode=U requestType=wait
  2018-05-08 14:21:15.75 spid28s        keylock hobtid=72057733317918720 dbid=14 objectname=Live.Erp.OrderHed indexname=IX_OrderHed_SysIndex id=lock127f6af100 mode=U associatedObjectId=72057733317918720
  2018-05-08 14:21:15.75 spid28s         owner-list
  2018-05-08 14:21:15.75 spid28s          owner id=process9d6486cf8 mode=U
  2018-05-08 14:21:15.75 spid28s         waiter-list
  2018-05-08 14:21:15.75 spid28s          waiter id=processa41673c38 mode=U requestType=wait

I also have this running:

Login to MS SQL Studio and run this (atleast then we can see the full Queries of causing the deadlock, which could assist in giving a better idea):

select * from ::fn_get_sql(0x02000000be9eab0f9c732486d11621d40c38bbbe3e0c4a470000000000000000000000000000000000000000)

select * from ::fn_get_sql(0x02000000aeb41125a834a0e952ac9ca7a5cfda6b4c6727ce0000000000000000000000000000000000000000)
  (@0 decimal(17,3),@1 decimal(17,3),@2 uniqueidentifier)update [Erp].[OrderHed]
  set [TotalTax] = @0, [DocTotalTax] = @1
  where ([SysRowID] = @2)
  select [SysRevID]
  from [Erp].[OrderHed]
  where @@ROWCOUNT > 0 and [SysRowID] = @2

.

  (@p__linq__0 uniqueidentifier)SELECT TOP (1) 
  [Extent2].[OpenOrder] AS [OpenOrder], 
  [Extent2].[VoidOrder] AS [VoidOrder], 
  [Extent2].[Company] AS [Company], 
  [Extent2].[OrderNum] AS [OrderNum], 
  [Extent2].[CustNum] AS [CustNum], 
  [Extent2].[PONum] AS [PONum], 
  [Extent2].[OrderHeld] AS [OrderHeld], 
  [Extent2].[EntryPerson] AS [EntryPerson], 
  [Extent2].[ShipToNum] AS [ShipToNum], 
  [Extent2].[RequestDate] AS [RequestDate], 
  [Extent2].[OrderDate] AS [OrderDate], 
  [Extent2].[FOB] AS [FOB], 
  [Extent2].[ShipViaCode] AS [ShipViaCode], 
  [Extent2].[TermsCode] AS [TermsCode], 
  [Extent2].[DiscountPercent] AS [DiscountPercent], 
  [Extent2].[PrcConNum] AS [PrcConNum], 
  [Extent2].[ShpConNum] AS [ShpConNum], 
  [Extent2].[SalesRepList] AS [SalesRepList], 
  [Extent2].[OrderComment] AS [OrderComment], 
  [Extent2].[ShipComment] AS [ShipComment], 
  [Extent2].[InvoiceComment] AS [InvoiceComment], 
  [Extent2].[PickListComment] AS [PickListComment], 
  [Extent2].[DepositBal] AS [DepositBal], 
  [Extent2].[DocDepositBal] AS [DocDepositBal], 
  [Extent2].[NeedByDate] AS [NeedByDate], 
  [Extent2].[CreditOverride] AS [CreditOverride], 
  [Extent2].[CreditOverrideUserID] AS [CreditOverrideUserID], 
  [Extent2].[CreditOverrideDate] AS [CreditOverrideDate], 
  [Extent2].[CreditOverrideTime] AS [CreditOverrideTime], 
  [Extent2].[CreditOverrideLimit] AS [CreditOverrideLimit], 
  [Extent2].[SndAlrtShp] AS [SndAlrtShp], 
  [Extent2].[ExchangeRate] AS [ExchangeRate], 
  [Extent2].[CurrencyCode] AS [CurrencyCode], 
  [Extent2].[LockRate] AS [LockRate], 
  [Extent2].[CardMemberName] AS [CardMemberName], 
  [Extent2].[CardNumber] AS [CardNumber], 
  [Extent2].[CardType] AS [CardType], 
  [Extent2].[ExpirationMonth] AS [ExpirationMonth], 
  [Extent2].[ExpirationYear] AS [ExpirationYear], 
  [Extent2].[CardID] AS [CardID], 
  [Extent2].[CardmemberReference] AS [CardmemberReference], 
  [Extent2].[AllocPriorityCode] AS [AllocPriorityCode], 
  [Extent2].[ReservePriorityCode] AS [ReservePriorityCode], 
  [Extent2].[ShipOrderComplete] AS [ShipOrderComplete], 
  [Extent2].[WebOrder] AS [WebOrder], 
  [Extent2].[CCApprovalNum] AS [CCApprovalNum], 
  [Extent2].[EDIOrder] AS [EDIOrder], 
  [Extent2].[EDIAck] AS [EDIAck], 
  [Extent2].[Linked] AS [Linked], 
  [Extent2].[ICPONum] AS [ICPONum], 
  [Extent2].[ExtCompany] AS [ExtCompany], 
  [Extent2].[WebEntryPerson] AS [WebEntryPerson], 
  [Extent2].[AckEmailSent] AS [AckEmailSent], 
  [Extent2].[ApplyOrderBasedDisc] AS [ApplyOrderBasedDisc], 
  [Extent2].[AutoOrderBasedDisc] AS [AutoOrderBasedDisc], 
  [Extent2].[EntryMethod] AS [EntryMethod], 
  [Extent2].[HDCaseNum] AS [HDCaseNum], 
  [Extent2].[CounterSale] AS [CounterSale], 
  [Extent2].[CreateInvoice] AS [CreateInvoice], 
  [Extent2].[CreatePackingSlip] AS [CreatePackingSlip], 
  [Extent2].[LockQty] AS [LockQty], 
  [Extent2].[ProcessCard] AS [ProcessCard], 
  [Extent2].[CCAmount] AS [CCAmount], 
  [Extent2].[CCFreight] AS [CCFreight], 
  [Extent2].[CCTax] AS [CCTax], 
  [Extent2].[CCTotal] AS [CCTotal], 
  [Extent2].[CCDocAmount] AS [CCDocAmount], 
  [Extent2].[CCDocFreight] AS [CCDocFreight], 
  [Extent2].[CCDocTax] AS [CCDocTax], 
  [Extent2].[CCDocTotal] AS [CCDocTotal], 
  [Extent2].[CCStreetAddr] AS [CCStreetAddr], 
  [Extent2].[CCZip] AS [CCZip], 
  [Extent2].[BTCustNum] AS [BTCustNum], 
  [Extent2].[BTConNum] AS [BTConNum], 
  [Extent2].[RepRate4] AS [RepRate4], 
  [Extent2].[RepRate5] AS [RepRate5], 
  [Extent2].[RepSplit1] AS [RepSplit1], 
  [Extent2].[RepSplit2] AS [RepSplit2], 
  [Extent2].[RepSplit3] AS [RepSplit3], 
  [Extent2].[RepSplit4] AS [RepSplit4], 
  [Extent2].[RepSplit5] AS [RepSplit5], 
  [Extent2].[RepRate1] AS [RepRate1], 
  [Extent2].[RepRate2] AS [RepRate2], 
  [Extent2].[RepRate3] AS [RepRate3], 
  [Extent2].[OutboundSalesDocCtr] AS [OutboundSalesDocCtr], 
  [Extent2].[OutboundShipDocsCtr] AS [OutboundShipDocsCtr], 
  [Extent2].[DemandContractNum] AS [DemandContractNum], 
  [Extent2].[DoNotShipBeforeDate] AS [DoNotShipBeforeDate], 
  [Extent2].[ResDelivery] AS [ResDelivery], 
  [Extent2].[DoNotShipAfterDate] AS [DoNotShipAfterDate], 
  [Extent2].[SatDelivery] AS [SatDelivery], 
  [Extent2].[SatPickup] AS [SatPickup], 
  [Extent2].[Hazmat] AS [Hazmat], 
  [Extent2].[DocOnly] AS [DocOnly], 
  [Extent2].[RefNotes] AS [RefNotes], 
  [Extent2].[ApplyChrg] AS [ApplyChrg], 
  [Extent2].[ChrgAmount] AS [ChrgAmount], 
  [Extent2].[COD] AS [COD], 
  [Extent2].[CODFreight] AS [CODFreight], 
  [Extent2].[CODCheck] AS [CODCheck], 
  [Extent2].[CODAmount] AS [CODAmount], 
  [Extent2].[GroundType] AS [GroundType], 
  [Extent2].[NotifyFlag] AS [NotifyFlag], 
  [Extent2].[NotifyEMail] AS [NotifyEMail], 
  [Extent2].[DeclaredIns] AS [DeclaredIns], 
  [Extent2].[DeclaredAmt] AS [DeclaredAmt], 
  [Extent2].[CancelAfterDate] AS [CancelAfterDate], 
  [Extent2].[DemandRejected] AS [DemandRejected], 
  [Extent2].[OverrideCarrier] AS [OverrideCarrier], 
  [Extent2].[OverrideService] AS [OverrideService], 
  [Extent2].[CreditCardOrder] AS [CreditCardOrder], 
  [Extent2].[DemandHeadSeq] AS [DemandHeadSeq], 
  [Extent2].[PayFlag] AS [PayFlag], 
  [Extent2].[PayAccount] AS [PayAccount], 
  [Extent2].[PayBTAddress1] AS [PayBTAddress1], 
  [Extent2].[PayBTAddress2] AS [PayBTAddress2], 
  [Extent2].[PayBTCity] AS [PayBTCity], 
  [Extent2].[PayBTState] AS [PayBTState], 
  [Extent2].[PayBTZip] AS [PayBTZip], 
  [Extent2].[PayBTCountry] AS [PayBTCountry], 
  [Extent2].[DropShip] AS [DropShip], 
  [Extent2].[CommercialInvoice] AS [CommercialInvoice], 
  [Extent2].[ShipExprtDeclartn] AS [ShipExprtDeclartn], 
  [Extent2].[CertOfOrigin] AS [CertOfOrigin], 
  [Extent2].[LetterOfInstr] AS [LetterOfInstr], 
  [Extent2].[FFID] AS [FFID], 
  [Extent2].[FFAddress1] AS [FFAddress1], 
  [Extent2].[FFAddress2] AS [FFAddress2], 
  [Extent2].[FFCity] AS [FFCity], 
  [Extent2].[FFState] AS [FFState], 
  [Extent2].[FFZip] AS [FFZip], 
  [Extent2].[FFCountry] AS [FFCountry], 
  [Extent2].[FFContact] AS [FFContact], 
  [Extent2].[FFCompName] AS [FFCompName], 
  [Extent2].[FFPhoneNum] AS [FFPhoneNum], 
  [Extent2].[IntrntlShip] AS [IntrntlShip], 
  [Extent2].[ChangedBy] AS [ChangedBy], 
  [Extent2].[ChangeDate] AS [ChangeDate], 
  [Extent2].[ChangeTime] AS [ChangeTime], 
  [Extent2].[AutoPrintReady] AS [AutoPrintReady], 
  [Extent2].[EDIReady] AS [EDIReady], 
  [Extent2].[IndividualPackIDs] AS [IndividualPackIDs], 
  [Extent2].[FFAddress3] AS [FFAddress3], 
  [Extent2].[DeliveryConf] AS [DeliveryConf], 
  [Extent2].[AddlHdlgFlag] AS [AddlHdlgFlag], 
  [Extent2].[NonStdPkg] AS [NonStdPkg], 
  [Extent2].[ServSignature] AS [ServSignature], 
  [Extent2].[ServAlert] AS [ServAlert], 
  [Extent2].[ServHomeDel] AS [ServHomeDel], 
  [Extent2].[DeliveryType] AS [DeliveryType], 
  [Extent2].[ServDeliveryDate] AS [ServDeliveryDate], 
  [Extent2].[ServInstruct] AS [ServInstruct], 
  [Extent2].[ServRef1] AS [ServRef1], 
  [Extent2].[ServRef2] AS [ServRef2], 
  [Extent2].[ServRef3] AS [ServRef3], 
  [Extent2].[ServRef4] AS [ServRef4], 
  [Extent2].[ServRef5] AS [ServRef5], 
  [Extent2].[FFCountryNum] AS [FFCountryNum], 
  [Extent2].[ServPhone] AS [ServPhone], 
  [Extent2].[ServRelease] AS [ServRelease], 
  [Extent2].[ServAuthNum] AS [ServAuthNum], 
  [Extent2].[PayBTAddress3] AS [PayBTAddress3], 
  [Extent2].[PayBTCountryNum] AS [PayBTCountryNum], 
  [Extent2].[PayBTPhone] AS [PayBTPhone], 
  [Extent2].[UPSQuantumView] AS [UPSQuantumView], 
  [Extent2].[UPSQVShipFromName] AS [UPSQVShipFromName], 
  [Extent2].[UPSQVMemo] AS [UPSQVMemo], 
  [Extent2].[ReadyToCalc] AS [ReadyToCalc], 
  [Extent2].[TotalCharges] AS [TotalCharges], 
  [Extent2].[TotalMisc] AS [TotalMisc], 
  [Extent2].[TotalDiscount] AS [TotalDiscount], 
  [Extent2].[TotalComm] AS [TotalComm], 
  [Extent2].[TotalAdvBill] AS [TotalAdvBill], 
  [Extent2].[TotalLines] AS [TotalLines], 
  [Extent2].[TotalReleases] AS [TotalReleases], 
  [Extent2].[TotalRelDates] AS [TotalRelDates], 
  [Extent2].[DocTotalCharges] AS [DocTotalCharges], 
  [Extent2].[DocTotalMisc] AS [DocTotalMisc], 
  [Extent2].[DocTotalDiscount] AS [DocTotalDiscount], 
  [Extent2].[DocTotalComm] AS [DocTotalComm], 
  [Extent2].[TotalTax] AS [TotalTax], 
  [Extent2].[DocTotalTax] AS [DocTotalTax], 
  [Extent2].[DocTotalAdvBill] AS [DocTotalAdvBill], 
  [Extent2].[TotalShipped] AS [TotalShipped], 
  [Extent2].[TotalInvoiced] AS [TotalInvoiced], 
  [Extent2].[TotalCommLines] AS [TotalCommLines], 
  [Extent2].[SRCommAmt1] AS [SRCommAmt1], 
  [Extent2].[SRCommAmt2] AS [SRCommAmt2], 
  [Extent2].[SRCommAmt3] AS [SRCommAmt3], 
  [Extent2].[SRCommAmt4] AS [SRCommAmt4], 
  [Extent2].[SRCommAmt5] AS [SRCommAmt5], 
  [Extent2].[SRCommableAmt1] AS [SRCommableAmt1], 
  [Extent2].[SRCommableAmt2] AS [SRCommableAmt2], 
  [Extent2].[SRCommableAmt3] AS [SRCommableAmt3], 
  [Extent2].[SRCommableAmt4] AS [SRCommableAmt4], 
  [Extent2].[SRCommableAmt5] AS [SRCommableAmt5], 
  [Extent2].[Rounding] AS [Rounding], 
  [Extent2].[Rpt1DepositBal] AS [Rpt1DepositBal], 
  [Extent2].[DocRounding] AS [DocRounding], 
  [Extent2].[Rpt2DepositBal] AS [Rpt2DepositBal], 
  [Extent2].[Rpt3DepositBal] AS [Rpt3DepositBal], 
  [Extent2].[Rpt1TotalCharges] AS [Rpt1TotalCharges], 
  [Extent2].[Rpt2TotalCharges] AS [Rpt2TotalCharges], 
  [Extent2].[Rpt3TotalCharges] AS [Rpt3TotalCharges], 
  [Extent2].[Rpt1TotalAdvBill] AS [Rpt1TotalAdvBill], 
  [Extent2].[Rpt2TotalAdvBill] AS [Rpt2TotalAdvBill], 
  [Extent2].[Rpt3TotalAdvBill] AS [Rpt3TotalAdvBill], 
  [Extent2].[Rpt1TotalMisc] AS [Rpt1TotalMisc], 
  [Extent2].[Rpt2TotalMisc] AS [Rpt2TotalMisc], 
  [Extent2].[Rpt3TotalMisc] AS [Rpt3TotalMisc], 
  [Extent2].[Rpt1TotalDiscount] AS [Rpt1TotalDiscount], 
  [Extent2].[Rpt2TotalDiscount] AS [Rpt2TotalDiscount], 
  [Extent2].[Rpt3TotalDiscount] AS [Rpt3TotalDiscount], 
  [Extent2].[Rpt1TotalComm] AS [Rpt1TotalComm], 
  [Extent2].[Rpt2TotalComm] AS [Rpt2TotalComm], 
  [Extent2].[Rpt3TotalComm] AS [Rpt3TotalComm], 
  [Extent2].[Rpt1TotalTax] AS [Rpt1TotalTax], 
  [Extent2].[Rpt2TotalTax] AS [Rpt2TotalTax], 
  [Extent2].[Rpt1Rounding] AS [Rpt1Rounding], 
  [Extent2].[Rpt2Rounding] AS [Rpt2Rounding], 
  [Extent2].[Rpt3Rounding] AS [Rpt3Rounding], 
  [Extent2].[RateGrpCode] AS [RateGrpCode], 
  [Extent2].[Rpt3TotalTax] AS [Rpt3TotalTax], 
  [Extent2].[Rpt1CCAmount] AS [Rpt1CCAmount], 
  [Extent2].[Rpt2CCAmount] AS [Rpt2CCAmount], 
  [Extent2].[Rpt3CCAmount] AS [Rpt3CCAmount], 
  [Extent2].[Rpt1CCFreight] AS [Rpt1CCFreight], 
  [Extent2].[Rpt2CCFreight] AS [Rpt2CCFreight], 
  [Extent2].[Rpt3CCFreight] AS [Rpt3CCFreight], 
  [Extent2].[Rpt1CCTax] AS [Rpt1CCTax], 
  [Extent2].[Rpt2CCTax] AS [Rpt2CCTax], 
  [Extent2].[Rpt3CCTax] AS [Rpt3CCTax], 
  [Extent2].[Rpt1CCTotal] AS [Rpt1CCTotal], 
  [Extent2].[Rpt2CCTotal] AS [Rpt2CCTotal], 
  [Extent2].[Rpt3CCTotal] AS [Rpt3CCTotal], 
  [Extent2].[OrderAmt] AS [OrderAmt], 
  [Extent2].[DocOrderAmt] AS [DocOrderAmt], 
  [Extent2].[Rpt1OrderAmt] AS [Rpt1OrderAmt], 
  [Extent2].[Rpt2OrderAmt] AS [Rpt2OrderAmt], 
  [Extent2].[Rpt3OrderAmt] AS [Rpt3OrderAmt], 
  [Extent2].[TaxPoint] AS [TaxPoint], 
  [Extent2].[TaxRateDate] AS [TaxRateDate], 
  [Extent2].[TaxRegionCode] AS [TaxRegionCode], 
  [Extent2].[UseOTS] AS [UseOTS], 
  [Extent2].[OTSName] AS [OTSName], 
  [Extent2].[OTSAddress1] AS [OTSAddress1], 
  [Extent2].[OTSAddress2] AS [OTSAddress2], 
  [Extent2].[OTSAddress3] AS [OTSAddress3], 
  [Extent2].[OTSCity] AS [OTSCity], 
  [Extent2].[OTSState] AS [OTSState], 
  [Extent2].[OTSZIP] AS [OTSZIP], 
  [Extent2].[OTSResaleID] AS [OTSResaleID], 
  [Extent2].[OTSContact] AS [OTSContact], 
  [Extent2].[OTSFaxNum] AS [OTSFaxNum], 
  [Extent2].[OTSPhoneNum] AS [OTSPhoneNum], 
  [Extent2].[OTSCountryNum] AS [OTSCountryNum], 
  [Extent2].[TotalWHTax] AS [TotalWHTax], 
  [Extent2].[DocTotalWHTax] AS [DocTotalWHTax], 
  [Extent2].[Rpt1TotalWHTax] AS [Rpt1TotalWHTax], 
  [Extent2].[Rpt2TotalWHTax] AS [Rpt2TotalWHTax], 
  [Extent2].[Rpt3TotalWHTax] AS [Rpt3TotalWHTax], 
  [Extent2].[TotalSATax] AS [TotalSATax], 
  [Extent2].[DocTotalSATax] AS [DocTotalSATax], 
  [Extent2].[Rpt1TotalSATax] AS [Rpt1TotalSATax], 
  [Extent2].[Rpt2TotalSATax] AS [Rpt2TotalSATax], 
  [Extent2].[Rpt3TotalSATax] AS [Rpt3TotalSATax], 
  [Extent2].[OTSSaveAs] AS [OTSSaveAs], 
  [Extent2].[OTSSaveCustID] AS [OTSSaveCustID], 
  [Extent2].[OTSCustSaved] AS [OTSCustSaved], 
  [Extent2].[ShipToCustNum] AS [ShipToCustNum], 
  [Extent2].[OrderStatus] AS [OrderStatus], 
  [Extent2].[HoldSetByDemand] AS [HoldSetByDemand], 
  [Extent2].[InPrice] AS [InPrice], 
  [Extent2].[InTotalCharges] AS [InTotalCharges], 
  [Extent2].[InTotalMisc] AS [InTotalMisc], 
  [Extent2].[InTotalDiscount] AS [InTotalDiscount], 
  [Extent2].[DocInTotalCharges] AS [DocInTotalCharges], 
  [Extent2].[DocInTotalMisc] AS [DocInTotalMisc], 
  [Extent2].[DocInTotalDiscount] AS [DocInTotalDiscount], 
  [Extent2].[Rpt1InTotalCharges] AS [Rpt1InTotalCharges], 
  [Extent2].[Rpt2InTotalCharges] AS [Rpt2InTotalCharges], 
  [Extent2].[Rpt3InTotalCharges] AS [Rpt3InTotalCharges], 
  [Extent2].[Rpt1InTotalMisc] AS [Rpt1InTotalMisc], 
  [Extent2].[Rpt2InTotalMisc] AS [Rpt2InTotalMisc], 
  [Extent2].[Rpt3InTotalMisc] AS [Rpt3InTotalMisc], 
  [Extent2].[Rpt1InTotalDiscount] AS [Rpt1InTotalDiscount], 
  [Extent2].[Rpt2InTotalDiscount] AS [Rpt2InTotalDiscount], 
  [Extent2].[Rpt3InTotalDiscount] AS [Rpt3InTotalDiscount], 
  [Extent2].[ARLOCID] AS [ARLOCID], 
  [Extent2].[OurBank] AS [OurBank], 
  [Extent2].[ERSOrder] AS [ERSOrder], 
  [Extent2].[LOCHold] AS [LOCHold], 
  [Extent2].[PSCurrCode] AS [PSCurrCode], 
  [Extent2].[InvCurrCode] AS [InvCurrCode], 
  [Extent2].[LegalNumber] AS [LegalNumber], 
  [Extent2].[TranDocTypeID] AS [TranDocTypeID], 
  [Extent2].[XRefContractNum] AS [XRefContractNum], 
  [Extent2].[XRefContractDate] AS [XRefContractDate], 
  [Extent2].[DemandProcessDate] AS [DemandProcessDate], 
  [Extent2].[DemandProcessTime] AS [DemandProcessTime], 
  [Extent2].[LastScheduleNumber] AS [LastScheduleNumber], 
  [Extent2].[LastTCtrlNum] AS [LastTCtrlNum], 
  [Extent2].[LastBatchNum] AS [LastBatchNum], 
  [Extent2].[ECCOrderNum] AS [ECCOrderNum], 
  [Extent2].[ECCPONum] AS [ECCPONum], 
  [Extent2].[WIOrder] AS [WIOrder], 
  [Extent2].[WIApplication] AS [WIApplication], 
  [Extent2].[WIUsername] AS [WIUsername], 
  [Extent2].[WIUserID] AS [WIUserID], 
  [Extent2].[WICreditCardorder] AS [WICreditCardorder], 
  [Extent2].[OrderCSR] AS [OrderCSR], 
  [Extent2].[UserChar1] AS [UserChar1], 
  [Extent2].[UserChar2] AS [UserChar2], 
  [Extent2].[UserChar3] AS [UserChar3], 
  [Extent2].[UserChar4] AS [UserChar4], 
  [Extent2].[UserDate1] AS [UserDate1], 
  [Extent2].[UserDate2] AS [UserDate2], 
  [Extent2].[UserDate3] AS [UserDate3], 
  [Extent2].[UserDate4] AS [UserDate4], 
  [Extent2].[UserDecimal1] AS [UserDecimal1], 
  [Extent2].[UserDecimal2] AS [UserDecimal2], 
  [Extent2].[UserInteger1] AS [UserInteger1], 
  [Extent2].[UserInteger2] AS [UserInteger2], 
  [Extent2].[SysRevID] AS [SysRevID], 
  [Extent1].[ForeignSysRowID] AS [ForeignSysRowID], 
  [Extent2].[IsCSRSet] AS [IsCSRSet], 
  [Extent2].[ECCPaymentMethod] AS [ECCPaymentMethod], 
  [Extent2].[AGUseGoodDefaultMark] AS [AGUseGoodDefaultMark], 
  [Extent2].[OTSShipToNum] AS [OTSShipToNum], 
  [Extent2].[ProFormaInvComment] AS [ProFormaInvComment], 
  [Extent2].[ccToken] AS [ccToken], 
  [Extent2].[InvcOrderCmp] AS [InvcOrderCmp], 
  [Extent2].[ReprintSOAck] AS [ReprintSOAck], 
  [Extent2].[CounterSOAck] AS [CounterSOAck], 
  [Extent2].[DispatchReason] AS [DispatchReason], 
  [Extent2].[Plant] AS [Plant], 
  [Extent2].[ReadyToFulfill] AS [ReadyToFulfill], 
  [Extent2].[ShipByTime] AS [ShipByTime], 
  [Extent2].[TWFiscalYear] AS [TWFiscalYear], 
  [Extent2].[TWFiscalYearSuffix] AS [TWFiscalYearSuffix], 
  [Extent2].[TWFiscalPeriod] AS [TWFiscalPeriod], 
  [Extent2].[TWGUIGroup] AS [TWGUIGroup], 
  [Extent2].[TWGUIRegNumSeller] AS [TWGUIRegNumSeller], 
  [Extent2].[TWGUIRegNumBuyer] AS [TWGUIRegNumBuyer], 
  [Extent2].[OrderOpenCredit] AS [OrderOpenCredit], 
  [Extent2].[ClosedNotShipped] AS [ClosedNotShipped], 
  [Extent1].[Character01] AS [Character01], 
  [Extent1].[Character02] AS [Character02], 
  [Extent1].[Character03] AS [Character03], 
  [Extent1].[Character04] AS [Character04], 
  [Extent1].[Character05] AS [Character05], 
  [Extent1].[Character06] AS [Character06], 
  [Extent1].[Character07] AS [Character07], 
  [Extent1].[Character08] AS [Character08], 
  [Extent1].[Character09] AS [Character09], 
  [Extent1].[Character10] AS [Character10], 
  [Extent1].[Number01] AS [Number01], 
  [Extent1].[Number02] AS [Number02], 
  [Extent1].[Number03] AS [Number03], 
  [Extent1].[Number05] AS [Number05], 
  [Extent1].[Number06] AS [Number06], 
  [Extent1].[Number07] AS [Number07], 
  [Extent1].[Date01] AS [Date01], 
  [Extent1].[Date03] AS [Date03], 
  [Extent1].[Date04] AS [Date04], 
  [Extent1].[Date05] AS [Date05], 
  [Extent1].[CheckBox01] AS [CheckBox01], 
  [Extent1].[CheckBox02] AS [CheckBox02], 
  [Extent1].[CheckBox03] AS [CheckBox03], 
  [Extent1].[CheckBox05] AS [CheckBox05], 
  [Extent1].[Number19] AS [Number19], 
  [Extent1].[Number20] AS [Number20], 
  [Extent1].[Date10] AS [Date10], 
  [Extent1].[Date11] AS [Date11], 
  [Extent1].[CheckBox06] AS [CheckBox06], 
  [Extent1].[CheckBox07] AS [CheckBox07], 
  [Extent1].[CheckBox10] AS [CheckBox10], 
  [Extent1].[CheckBox11] AS [CheckBox11], 
  [Extent1].[CheckBox12] AS [CheckBox12], 
  [Extent1].[CheckBox16] AS [CheckBox16], 
  [Extent1].[CheckBox17] AS [CheckBox17], 
  [Extent1].[CheckBox18] AS [CheckBox18], 
  [Extent1].[CheckBox19] AS [CheckBox19], 
  [Extent1].[CheckBox20] AS [CheckBox20], 
  [Extent1].[ShortChar01] AS [ShortChar01], 
  [Extent1].[ShortChar02] AS [ShortChar02], 
  [Extent1].[ShortChar03] AS [ShortChar03], 
  [Extent1].[ShortChar04] AS [ShortChar04], 
  [Extent1].[ShortChar05] AS [ShortChar05], 
  [Extent1].[ShortChar06] AS [ShortChar06], 
  [Extent1].[ShortChar07] AS [ShortChar07], 
  [Extent1].[ShortChar08] AS [ShortChar08], 
  [Extent1].[ShortChar09] AS [ShortChar09], 
  [Extent1].[ShortChar10] AS [ShortChar10], 
  [Extent1].[UD_SysRevID] AS [UD_SysRevID], 
  [Extent1].[CustName_c] AS [CustName_c], 
  [Extent1].[Number10] AS [Number10], 
  [Extent1].[PMEmail_c] AS [PMEmail_c], 
  [Extent1].[RepEmail_c] AS [RepEmail_c], 
  [Extent1].[ShipWhenReady_c] AS [ShipWhenReady_c], 
  [Extent1].[InstallOrderInt_c] AS [InstallOrderInt_c], 
  [Extent1].[Offset_c] AS [Offset_c], 
  [Extent1].[SeatCount_c] AS [SeatCount_c], 
  [Extent1].[PSalesCat_c] AS [PSalesCat_c], 
  [Extent1].[PM_ConstPermit_c] AS [PM_ConstPermit_c], 
  [Extent1].[PM_ConstSchedValid_c] AS [PM_ConstSchedValid_c], 
  [Extent1].[PM_CoreDrillPlan_c] AS [PM_CoreDrillPlan_c], 
  [Extent1].[PM_CoreDrillPlanNA_c] AS [PM_CoreDrillPlanNA_c], 
  [Extent1].[PM_DepositRcv_c] AS [PM_DepositRcv_c], 
  [Extent1].[PM_DepositRcvNA_c] AS [PM_DepositRcvNA_c], 
  [Extent1].[PM_FieldDim_c] AS [PM_FieldDim_c], 
  [Extent1].[PM_FieldDimNA_c] AS [PM_FieldDimNA_c], 
  [Extent1].[PM_FinalPlanSet_c] AS [PM_FinalPlanSet_c], 
  [Extent1].[PM_FinalPlanSetNA_c] AS [PM_FinalPlanSetNA_c], 
  [Extent1].[PM_FinalSiteReady_c] AS [PM_FinalSiteReady_c], 
  [Extent1].[PM_OrderApproved_c] AS [PM_OrderApproved_c], 
  [Extent1].[PM_OrderApprovedNA_c] AS [PM_OrderApprovedNA_c], 
  [Extent1].[PM_OrderComfirm_c] AS [PM_OrderComfirm_c], 
  [Extent1].[PM_SignedContract_c] AS [PM_SignedContract_c], 
  [Extent1].[PM_SiteContactInfo_c] AS [PM_SiteContactInfo_c], 
  [Extent1].[PM_TwoWeekNotice_c] AS [PM_TwoWeekNotice_c]
  FROM  [Erp].[OrderHed_UD] AS [Extent1] WITH (UPDLOCK) 
  INNER JOIN [Erp].[OrderHed] AS [Extent2] WITH (UPDLOCK)  ON [Extent1].[ForeignSysRowID] = [Extent2].[SysRowID]
  WHERE ([Extent1].[ForeignSysRowID] = @p__linq__0) AND (@p__linq__0 IS NOT NULL)
1 Like

Do you have a BPM, Avalara or something else calculating TotalTax or running at the same with with an Update LockHint? Multi-Currency?

If not at the least submit those 2 Queries to your Epicor Support Case and try a SQL Restart to see if it releases locks (on weekend).

But before you do that can you go to your System Agent and Display All Tasks, see if you have a Task or a Process stuck in the Active Queue which may be holding a lock on the Order, if so click it and delete it.

We have locks usually when MRP Crashes and remains in β€œActive” state.

In addition go to your Windows Event Viewer where you Task Agent is at and glance at it for any additional logs - Agent will write to Event Viewer.

Yes, we use Avalara. I just tried turning it off, but it still comes up with the deadlock error.
No other BPMs touching tax.

No hung tasks and the event viewer is showing the same error message as originally posted with no extra info.

Lastly what about Recycle IIS Poll assuming it has some w3wp process thats dead lurking - won’t disconnect users will slow them down for a few minutes.

1 Like

Success! Thanks!!

1 Like