troubleshooting Question

need to enter duplicate value in database for a unique identifier but getting error need work around

Avatar of sadaf_syed
sadaf_syed asked on
Microsoft SQL ServerSQL
15 Comments1 Solution255 ViewsLast Modified:
I am entering a value in our datbase that is a duplicate, its a company  thing. they used to do it here before but as im new im dont know the workaround for this.
im getting the error:
Server: Msg 2627, Level 14, State 1, Line 1
Violation of PRIMARY KEY constraint 'aaaaaECOBODY_PK'. Cannot insert duplicate key in object 'ECOBODY'.
The statement has been terminated.
when I type the query:
update ecobody set RevTo='B' where PartNumber='5002265G' and ECONumber='6690'

need a workaround for that error so that this change can be made to the database.
Join the community to see this answer!
Join our exclusive community to see this answer & millions of others.
Unlock 1 Answer and 15 Comments.
Join the Community
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 15 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros