Violation of PRIMARY KEY constraint 'Closeout_PK'. Cannot insert duplicate key in object 'dbo.Closeout'

The error appears when attempting to access any reports immediately after loading Control. This issue is caused by the -1 record in the Closeout table having a StoreID of -1 instead of 0.

  1. Open SQL Management Studio
  2. Execute the SQL statement below
UPDATE Closeout SET StoreID = 0 WHERE ID = -1

Upgrade to Control 5.1 or later.

Contributor: Brandon R.

Date: 4/21/2014

Version Affected: Control 4.6

You could leave a comment if you were logged in.