Page 1 of 2

SQL Error DBCode: 7 ...

PostPosted: Thu Mar 27, 2008 8:34 pm
by seewii
Message:
DBCode: 7 Error Text: SQLSTATE = S1000
ERROR: duplicate key violates unique constraint "game_players_idx_01"

How to proceed?! TY!!!

Re: SQL Error DBCode: 7 ...

PostPosted: Thu Mar 27, 2008 10:35 pm
by ptrack pat
When exactly do you get this error? When importing hands??

What email did you use to register PT? I have no record of this one used for the forum.

Re: SQL Error DBCode: 7 ...

PostPosted: Fri Mar 28, 2008 6:04 am
by seewii
I have made a new account in this new forum.
Regsitered: [removed by ptrack pat]

I got this problem within my sessions yesterday.

Re: SQL Error DBCode: 7 ...

PostPosted: Fri Mar 28, 2008 8:19 am
by ptrack pat
Go to the Utilities/Database Maintenance and Options window.

Click on the database description text at the top left corner of the window.
Then hit the F11 key on your PC. This will cause another tab to appear
called "Orphaned Data". You will need to use the little arrow icons that
appear at the top right corner of the tab to scroll to see this new tab.

Click on the "RingCheck" button. This may take a little while to run
especially if you have a lot of hands so just let it come back and prompt
you when it's done. Once it comes back, click the "Fix Now" button. This
will run through and clean up all the orphaned records so that you can
import the hands again. Let me know how this works.

Re: SQL Error DBCode: 7 ...

PostPosted: Fri Mar 28, 2008 8:34 am
by seewii
First it works, but when I import the HH again, I will get the message again.

I tried to import every only one silnge HH txt.file but I will get the message by each of them?!

Re: SQL Error DBCode: 7 ...

PostPosted: Fri Mar 28, 2008 8:44 am
by ptrack pat
When you ran that function, did it tell you that there were some orphaned records that it needed to fix? Or did it say there weren't any?

Did it actually import some hands after you fixed it or it didn't import anything, you just got the same error?

Have you been doing anything with your aliases? Added any aliases under your name?

Re: SQL Error DBCode: 7 ...

PostPosted: Fri Mar 28, 2008 8:54 am
by seewii
When I ran the function first time it tells me (and shows it also in the list) that there is something I can fix - Than I click the "Fix it" button.
After that I´ll got the message "The Data is fixed now".

When I know start to import the HH´s again, the systems give me the error message (as shown in my first post). Then it tells me that nothing is imported and nothing happened.

Yes, I have 3 or alliases under my name.

Re: SQL Error DBCode: 7 ...

PostPosted: Fri Mar 28, 2008 9:02 am
by ptrack pat
When did you convert to PostgreSQL?
Have you made any backups of the database prior to this error starting?

Re: SQL Error DBCode: 7 ...

PostPosted: Fri Mar 28, 2008 9:05 am
by seewii
minimum 6 months ago when I converted

last back-up was may be 1 week ago

Re: SQL Error DBCode: 7 ...

PostPosted: Fri Mar 28, 2008 9:16 am
by ptrack pat
I would recommend this...

1. backup the database again now just to be safe. Make sure you use a different name for the backup file DO NOT overwrite the one you made a week ago.

2. Use the Utilities > Export Hand Histories To File window to export all the hands since the date of the last backup to text files.

3. Restore the database from the backup file you made a week ago.

4. After the restore, reimport the files that were exported in step 2 using the Select Files To Import button on the File > Import Hand Histories/Tournament Summaries window.

highfalutin