Transfer of data

PostgreSQL is the database server used to store information. Do you have a question or are you having problem with PostgreSQL? If so, post them here.

Moderator: Moderators

Transfer of data

Postby Mountain runner » Sun May 15, 2011 7:19 pm

I had to reboot my PC and after that I couldnt set up my old Postgres database to work, so I moved it to another disc as a back up and created new Postgres database that works with PT3. The thing is, I had 30GB of hand histories on my old database and I want to somehow add them to my new database.
What is the best way to do it? Can I somehow copy-past the files from "PostgreSQL\8.3\data\base" folders or there is another way to do it?
Mountain runner
 
Posts: 15
Joined: Tue Dec 29, 2009 8:36 pm

Re: Transfer of data

Postby WhiteRider » Mon May 16, 2011 3:46 am

Do you mean you had to reinstall, rather than "reboot"?

If you still have the original hand history files you will probably find it easiest to re-import from those into your new database.
Otherwise you should be able to reconnect to the old data folder if you still have that on your old disk? You will need to uninstall PostgreSQL, data folder to the new location, and reinstall PostgreSQL – see the guide in the Documentation.
WhiteRider
Moderator
 
Posts: 54017
Joined: Sat Jan 19, 2008 7:06 pm
Location: UK

Re: Transfer of data

Postby Mountain runner » Mon May 16, 2011 12:25 pm

Yes, reinstall.
No, I dont have the original hh files, only a very small part of them.
I have moved the old data folder to another disk, uninstalled old Postgres and installed new Postgres which is empty now. How can I add my old database to it, if it is on another disk?
Mountain runner
 
Posts: 15
Joined: Tue Dec 29, 2009 8:36 pm

Re: Transfer of data

Postby kraada » Mon May 16, 2011 12:54 pm

If you have the entire PostgreSQL folder from the other computer you can put it on top of the current folder in your location (provided you're running the same PostgreSQL version) and the database should start up properly.
kraada
Moderator
 
Posts: 54431
Joined: Wed Mar 05, 2008 2:32 am
Location: NY

Re: Transfer of data

Postby Mountain runner » Mon May 16, 2011 4:14 pm

I did it in the beginning but PT3 said it could not connect to the database.
So what should I do now - delete the new Postgres and copy in its place the new one? They are both 8.3. The new one is just the latest version of 8.3.
Should the folders be named the same or it doesn't matter?
Mountain runner
 
Posts: 15
Joined: Tue Dec 29, 2009 8:36 pm

Re: Transfer of data

Postby kraada » Mon May 16, 2011 4:17 pm

Rename the working PostgreSQL folder to something else, and then rename the old PostgreSQL folder to PostgreSQL so that it's in the exact same place as the previous working installation. If all of the files are in the right place it should start up. If it doesn't, please report this problem and include any errors listed in Event Viewer (you can find Event Viewer in Start -> Control Panel -> Administrative Tools) and we'll investigate further for you.
kraada
Moderator
 
Posts: 54431
Joined: Wed Mar 05, 2008 2:32 am
Location: NY

Re: Transfer of data

Postby Mountain runner » Mon May 16, 2011 5:18 pm

Cannot rename the working service, it says, it is used by another programm.
Mountain runner
 
Posts: 15
Joined: Tue Dec 29, 2009 8:36 pm

Re: Transfer of data

Postby Mountain runner » Mon May 16, 2011 5:20 pm

Should I stop Postgres from running and then remove the new folder of Postgres (which is named Postgres NEW) and replace it with the old Postgres folder and finally rename it to Postres NEW ?
Mountain runner
 
Posts: 15
Joined: Tue Dec 29, 2009 8:36 pm

Re: Transfer of data

Postby kraada » Mon May 16, 2011 5:24 pm

The service name doesn't matter. But you'll need to stop the service before proceeding.

Currently there is some directory like C:\Program Files (x86)\PostgreSQL\ - it has an 8.3 subfolder which has many other folders beneath it.

With the service stopped rename that directory to something else.

Currently you have some other directory called, say, C:\PostgreSQLOLD\. Rename/move it so that it's now the C:\Program Files (x86)\PostgreSQL directory (if that's in fact where your working PostgreSQL directory was).

Then attempt to restart the server.
kraada
Moderator
 
Posts: 54431
Joined: Wed Mar 05, 2008 2:32 am
Location: NY

Re: Transfer of data

Postby Mountain runner » Mon May 16, 2011 5:46 pm

Ok, did that. Renamed the new folder and also renamed the old folder with the name of the "new folder".
But when I tried to start Postgres in sevices.cms it says "Windows could not start the Postgres SQL Database Server 8.3 service on Local computer. Error 2: The system cannot find the file specified."
Mountain runner
 
Posts: 15
Joined: Tue Dec 29, 2009 8:36 pm

Next

Return to PostgreSQL [Read Only]

Who is online

Users browsing this forum: No registered users and 22 guests

cron
highfalutin