Hello!
We use the oob process “Get shipments” or called “Create invoices from shipments process” to automatically generate invoices on a recurring schedule. We are now noticing this process is generating zero dollar invoices from sales order shipments. Has anyone else ran into this? This is causing a huge headache for our A/R department. I have engaged support and they are still investigating as well.
The Header Misc Charges are applied to the last line of the invoice. Epicor has been doing that for several versions. Mostly for the printing of the invoice. The invoice Header has no misc charges so they add it to the last line.
We have a change log enabled on invcdtl and an auto print 810 edi data directive on invoice head. Its defenitly related to the task agent failing however, as all the bad invoice times correlate with when there was a task agent error.
We get task agent errors such as:
System.Data.SqlClient.SqlException (0x80131904): A transport-level error has occurred when receiving results from the server. (provider: Session Provider, error: 19 - Physical connection is not usable)
at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection, Action`1 wrapCloseInAction)
also we saw one with:
Program Ice.Services.Lib.RunTask raised an unexpected exception with the following message: RunTask: An error occurred while updating the entries. See the inner exception for details.
Stack Trace:
at System.Data.Entity.Core.Mapping.Update.Internal.UpdateTranslator.Update()
at System.Data.Entity.Core.Objects.ObjectContext.ExecuteInTransaction[T](Func`1 func, IDbExecutionStrategy executionStrategy, Boolean startLocalTransaction, Boolean releaseConnectionOnSuccess)
at System.Data.Entity.Core.Objects.ObjectContext.SaveChangesToStore(SaveOptions options, IDbExecutionStrategy executionStrategy, Boolean startLocalTransaction)
at System.Data.Entity.Core.Objects.ObjectContext.SaveChangesInternal(SaveOptions options, Boolean executeInExistingTransaction)
at Ice.IceDataContext.SaveChanges(SaveOptions options) in C:\_Releases\ICE\ICE3.2.300.15\Source\Framework\Epicor.System\Data\IceDataContext.cs:line 356
at Ice.IceDataContext.Validate[TLinqRow](TLinqRow row) in C:\_Releases\ICE\ICE3.2.300.15\Source\Framework\Epicor.System\Data\IceDataContext.cs:line 317
at Erp.Internal.AR.CreateInvFromShip.setInvoiceGroupActiveUserID(String vGroupID, String userID) in C:\_projects\ERP\RL10.2.300.0\Source\Server\Internal\AR\CreateInvFromShip\CreateInvFromShip.cs:line 148
at Erp.Internal.AR.CreateInvFromShip.RunProcess(Int64 InstanceTaskNum, String OutputFileName) in C:\_projects\ERP\RL10.2.300.0\Source\Server\Internal\AR\CreateInvFromShip\CreateInvFromShip.cs:line 115
at Ice.Core.TaskBase`1.StartProcess(Int64 instanceTaskNum, String outputFileName) in C:\_Releases\ICE\ICE3.2.300.15\Source\Server\Internal\Lib\TaskLib\TaskBase\TaskBase.cs:line 47
at Ice.Hosting.TaskCaller.InnerExecuteTask(IceDataContext newContext) in C:\_Releases\ICE\ICE3.2.300.15\Source\Framework\Epicor.Ice\Hosting\TaskCaller\TaskCaller.cs:line 98
at Ice.Hosting.TaskCaller.ExecuteTask() in C:\_Releases\ICE\ICE3.2.300.15\Source\Framework\Epicor.Ice\Hosting\TaskCaller\TaskCaller.cs:line 57
at Ice.Lib.RunTask.BpmFriendlyTaskLauncher.Run(String sessionIdPrefix, IceContext db, Action taskRunner) in c:\_Releases\ICE\RL3.2.300.0\Source\Server\Services\Lib\RunTask\BpmFriendlyTaskLauncher.cs:line 63
at Ice.Services.Lib.RunTaskSvc.InnerRunTask(Int64 ipTaskNum, Boolean suppressTransaction) in c:\_Releases\ICE\RL3.2.300.0\Source\Server\Services\Lib\RunTask\RunTask.cs:line 577
Inner Exception:
Violation of PRIMARY KEY constraint 'PK_CurrExChain'. Cannot insert duplicate key in object 'Erp.CurrExChain'. The duplicate key value is (TPG, InvcHead, 1481702, , , , , , , , USD, 1).
The statement has been terminated.