iVend Stock transfer duplicate data in InvBatch

iVend Stock transfer duplicate data in InvBatch

******Internal to Citixsys******

Environment: 

6.5 Update 6 Patch 2  

Problem statement:

At the time of creating stock transfer below error occurred.
Load failed Criteria -Nhibernate.Criterion.Queryover'2[CXS.SubSystem.Inventoty.Batch,CXS.SubSystsem.Inventory.Batch]



Proposed solution: 

This issue can be resolved by  sql query. we applied SQL queries to correct the information on store and suggested to plan the inventory match.
Issue is only reported on dated version and is not noticed on the latest branch of iVend release available for the production use

Below are the steps we require to follow-up to resolve the issue.
Step 1: Query used for checking duplicate data on Invbatch table.
Select IB.* from InvBatch IB JOIN (
select productkey,warehousekey,batchnumber from InvBatch
group by productkey,warehousekey, batchnumber
having count(1) > 1) GB
ON IB.productkey = GB.productkey AND IB.WarehouseKey = GB.WarehouseKey AND IB.BatchNumber = GB.BatchNumber 
Step 2: Backup of Invbatach Table.
Step 3: Query used for delete duplicate data on Invbatch table.
With CTE as
(
Select IB.Batchkey,IB.productkey,IB.warehousekey,IB.batchnumber,row_number() over (partition by IB.productkey,IB.warehousekey,IB.batchnumber order by IB.Batchkey) as BatchRowNumber from InvBatch IB JOIN (
select productkey,warehousekey,batchnumber from InvBatch
group by productkey,warehousekey, batchnumber
having count(1) > 1) GB
ON IB.productkey = GB.productkey AND IB.WarehouseKey = GB.WarehouseKey AND IB.BatchNumber = GB.BatchNumber
)
Delete from invbatch where batchkey in (Select batchkey from CTE where BatchRowNumber > 1 )
This article is created only for Support team and will be done along  with  product expert.


    • Related Articles

    • Duplicate Stock Transfer Shipment

      Environment: iVend 6.5 Update 6 Problem Statement: While making a Stock Transfer receipt on receiving store MC, the user noticed that Stock Transfer Shipment is duplicated. Proposed Solution: CheckPoints: Check If stock Transfer Shipment Series is ...
    • General Settings in SAP Business One

      Introduction The iVend Add-on helps in setting up some configurations required for integrating iVend with SAP Business One. The following sections of this document capture the functionality of the new screens created and new fields added to the SAP ...
    • Stock transfer created from SAP B1 not integrating with iVend

      Environment iVend 6.5 Update 6 and 6.6 with SAPB1 9.2 Problem Statement Stock transfer created from SAP B1 not integrating with iVend Symptoms No integration record in CXSintegration and no stuck record. Resolution/Workaround When user makes Stock ...
    • iVend POS - Stock Transfer Cancellation

      Introduction iVend Retail POS versions 6.2 and above, the user is now allowed to cancel the Stock Transfer Shipment created from the store where the goods are being shipped from. The warehouse from where the goods are being shipped creates the Stock ...
    • Integration failure log : "Not enough data" : Not Able to Receive a Stock Transfer in SAPB1

      Environment : iVend 6.6 with SAP B1 9.2 Problem statement : When trying to perform a stock transfer receipt of an open stock transfer that comes from a store through the AddOn option: INVENTORY -> STORE TRANSFER -> STOCK TRANSFER RECEIPT and the ...