Troubleshooting: Change Item Code error - Violation of PRIMARY KEY constraint PK ItemLocationPrice

Question : Merge item code prompted application error – Violation of PRIMARY KEY constraint PK_ItemLocationPrice. Cannot insert duplicate key in object dbo.ItemLocationPrice.

Version : 1.8 / 1.9 / 2.0

Primary key itemlocationprice1.png

Possible Reason :

Both Item 1 and Item 2 have records for Item Price by Location. This is a conflict for item merge.

Solution :

1) Go to Stock > More Stock Maintenance > Item Price by Location Maintenance.

Primary key itemlocationprice2.png

2) Check the checkbox of one selected record to delete and click on Save.

Primary key itemlocationprice3.png

3) Perform again change and merge item code, it will be completed successfully.

Primary key itemlocationprice4.png

Primary key itemlocationprice5.png

By : Zhi Lin 200807, Lay Swan 200824, P200826

Go to menu

  AutoCount Accounting 2.0

  AutoCount Accounting 1.8 / 1.9
  AutoCount Payroll
  AutoCount POS

  AutoCount On The Go
  AutoCount Accounting Plug-In Documentations