Intercompany Configurator Error ' Duplicate Key in Erp.GlbPcRules'

Long shot on this one, anyone had issues with intercompany configurators?
We have 4 compnaies that share a configurator - it works in the parent and one child - when we switrch other companies on we get the following error:
System.Data.SqlClient.SqlException: Violation of PRIMARY KEY constraint ‘PK_GlbPcRules’. Cannot insert duplicate key in object ‘Erp.GlbPcRules’
Looking at the table the values dont exist!
Thanks for reading

Oh boy, have we ever! We’re considering re-racking everything as single company because Configurator Sync Direct Server Process hangs and Epicor can’t tell us why. We’re on cloud, so we can’t see the logs. We can’t even kill the hung task ourselves. We only went multi-company in the first place because configured manufactured products weren’t tying back to the sales orders, and Epicor told my predecessors that multi-company was the only way to make that work.


Yikes. Many times we had to try and re-import the configurator to solve weird issues like this. Try it in a test environment and see what happens.

1 Like

was it the same error? we have tried creating new configurators (export import) - but it only sticks on one of the configurators - which seems really odd.

Hm, no I have never encountered this error, just errors like it.

I’m not familiar with this error, but am mighty familiar with databases. That primary key is comprehensively, boldly even, composed of: Company, ConfigID, RuleSeq, AltMethod, RuleSetID, GlbCompany, GlbPartNum, and GlbRevisionNum.

SQL Server won’t allow you to insert a duplicate PK, which is kind of the point of PK’s. I’ve definitely been finding plenty of software managed data relationships and constraints, but I’d be surprised if that went as far as a software-managed “primary key”. I’d grab all 8 fields from that table in a quick BAQ for starters. It’s worth checking for duplicates as a sanity check since it only takes a moment. Give it a look over for things that don’t look right. Then keep an eye on it while exporting / deleting / importing the configurator to see if the configurator’s data isn’t completely removed from the table after deleting the configurator.

If something sticks out here, you might be able to work around it by renaming the colliding objects without having to wait for support to fix things.

1 Like

If you enable server tracing and provide the full error stack I can try identifying the source and maybe a workaround, I am familiar with multicompany but not related to the configurator.

Thanks Jonathan - I’m just setting up a new environment so I don’t mess up the one we are working in!
Much appreciate the help