"An item with the same key has already been added"

So this morning I logged in and had this error

“an item with the same key has already been added” and could not load the home page.

There are various topics on this issue, rather old, and rather than Necro posting and putting it all together. I thought I’d add another one to the pile. :slight_smile:

I could log into the kinetic UI via the browser with the same user account, I could even login to the classic on the same machine as a different user account. (Shift+right mouse on the shortcut, run as other user). In both situations it worked.

What ended up fixing the issue was to login as another user and use personalization purge and purge out the Main Menu history personalization for that account

I hope that helps someone in the future.

3 Likes

I typically encounter this error when:

  • Explicitly adding an IceColumn to a DataTable when the column already exists
  • SQL to BAQ Conversion that aliases a column with the same alias more than once

Generally, adding a column that exists already.

Educated guess is that there was something creating a dupe key in the buildout of menu history, only when personalizations were layered on. Probably if we saw the personalization it would stand out.

All I can say is I was logging in ok yesterday, then this morning it stopped. It’s one of those situations, stop doing anything and investigate or, just fix it and move on, sure I could have just proceeded with using another account and came back to it later… Hindsight and all.

Just wanted to post, what worked for me.

1 Like