SQL Error DBCode: 7 ...

Forum with tips, support, etc, on using the PostgreSQL database with Poker Tracker. Please post any PostgreSQL questions here.

SQL Error DBCode: 7 ...

Postby seewii » Thu Mar 27, 2008 8:34 pm

Message:
DBCode: 7 Error Text: SQLSTATE = S1000
ERROR: duplicate key violates unique constraint "game_players_idx_01"

How to proceed?! TY!!!
seewii
 
Posts: 7
Joined: Thu Mar 27, 2008 6:16 pm

Re: SQL Error DBCode: 7 ...

Postby ptrack pat » Thu Mar 27, 2008 10:35 pm

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.
ptrack pat
 
Posts: 4841
Joined: Sun Dec 09, 2007 12:38 pm

Re: SQL Error DBCode: 7 ...

Postby seewii » Fri Mar 28, 2008 6:04 am

I have made a new account in this new forum.
Regsitered: [removed by ptrack pat]

I got this problem within my sessions yesterday.
seewii
 
Posts: 7
Joined: Thu Mar 27, 2008 6:16 pm

Re: SQL Error DBCode: 7 ...

Postby ptrack pat » Fri Mar 28, 2008 8:19 am

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.
ptrack pat
 
Posts: 4841
Joined: Sun Dec 09, 2007 12:38 pm

Re: SQL Error DBCode: 7 ...

Postby seewii » Fri Mar 28, 2008 8:34 am

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?!
seewii
 
Posts: 7
Joined: Thu Mar 27, 2008 6:16 pm

Re: SQL Error DBCode: 7 ...

Postby ptrack pat » Fri Mar 28, 2008 8:44 am

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?
ptrack pat
 
Posts: 4841
Joined: Sun Dec 09, 2007 12:38 pm

Re: SQL Error DBCode: 7 ...

Postby seewii » Fri Mar 28, 2008 8:54 am

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.
seewii
 
Posts: 7
Joined: Thu Mar 27, 2008 6:16 pm

Re: SQL Error DBCode: 7 ...

Postby ptrack pat » Fri Mar 28, 2008 9:02 am

When did you convert to PostgreSQL?
Have you made any backups of the database prior to this error starting?
ptrack pat
 
Posts: 4841
Joined: Sun Dec 09, 2007 12:38 pm

Re: SQL Error DBCode: 7 ...

Postby seewii » Fri Mar 28, 2008 9:05 am

minimum 6 months ago when I converted

last back-up was may be 1 week ago
seewii
 
Posts: 7
Joined: Thu Mar 27, 2008 6:16 pm

Re: SQL Error DBCode: 7 ...

Postby ptrack pat » Fri Mar 28, 2008 9:16 am

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.
ptrack pat
 
Posts: 4841
Joined: Sun Dec 09, 2007 12:38 pm

Next

Return to PostgreSQL Forum

Who is online

Users browsing this forum: No registered users and 2 guests

cron