Guild of Project Controls: Compendium | Roles | Assessment | Certifications | Membership

Tips on using this forum..

(1) Explain your problem, don't simply post "This isn't working". What were you doing when you faced the problem? What have you tried to resolve - did you look for a solution using "Search" ? Has it happened just once or several times?

(2) It's also good to get feedback when a solution is found, return to the original post to explain how it was resolved so that more people can also use the results.

duplicate key in object 'dbo.TRSRCFIN'.

3 replies [Last post]
Gün Göksu
User offline. Last seen 1 year 41 weeks ago. Offline
Joined: 31 Mar 2005
Posts: 123

Hi everyone,

I am working on a system running MSSQL and P6 EPPM v15.2.

Trying to import a schedule backup in XML form with baseline into the database through P6 client.

SEVERE: DBEngine.executeUpdate: Violation of PRIMARY KEY constraint 'pk_trsrcfin'. Cannot insert duplicate key in object 'dbo.TRSRCFIN'. The duplicate key value is (150, 6275459).

This prevents me from importing the backup.

I get the same error on both the production and the backup testing server.

 Anyone encountered this before? a google search and an oracle support search did not turn anything usefull. Kind regards,Gün

Replies

Zoltan Palffy
User offline. Last seen 4 weeks 2 days ago. Offline
Joined: 13 Jul 2009
Posts: 3089
Groups: None

glad that I could help you

Gün Göksu
User offline. Last seen 1 year 41 weeks ago. Offline
Joined: 31 Mar 2005
Posts: 123

Thanks for the reply Zoltan,

I have figured as much, and a quick chat with someone who has been here (the office) longer confirms the financial periods have been changed.

I managed to import the XML files by deleting the financialperiod tag.

however, it is interesting that the dbo.TRSRCFIN table is actually empty.

Thanks also for the tip on the patch set.

Kind regards,

Edit: This is the bit I removed. maybe it'l be usefull to someone who stumbles here.

<FinancialPeriod><EndDate>2013-06-30T00:00:00</EndDate><Name>2013-06-01</Name><ObjectId>155</ObjectId><StartDate>2013-06-01T00:00:00</StartDate></FinancialPeriod>
Zoltan Palffy
User offline. Last seen 4 weeks 2 days ago. Offline
Joined: 13 Jul 2009
Posts: 3089
Groups: None

The error TRSRCFIN has to with the financial periods for the resource assignments. 

you need Release 15.2.3.0 Patch Set

since it is a xml file I am not sure that you can change it 

try to open the sml in a text editior and do a search for (150, 6275459) it should be in there twice. Whne you find it delete one of the instances.