It appears you have not yet registered with DEVPPL. To register please click here... (it's fast, easy and free!)

Forum

Log In Sponsors
Board index Programming PHP and MySQL Forum

How do I move data from a database into another database.

Moderator: Malcolm

How do I move data from a database into another database.

Postby Tomi on Fri Nov 28, 2008 3:45 pm

Specificaly I have a website with 12,000 members including username, password and email address. What I want to do is open a forum on my site but not have to make each member register again so i want to copy my site database into my forum user database... I plan to use PHPBB.

Thanks
User avatar
Tomi
500+ Club
 
Posts: 925
Joined: Mon Jun 26, 2006 6:51 pm
Location: Essex, England

Re: How do I move data from a database into another database.

Postby Johnathan on Fri Nov 28, 2008 6:40 pm

Don't know if there is a proper way but I would export the db as a SQL file then open it in wordpad or something with a find and replace thing and just rename thing like the password, email address and username to whatever phpbb asks for then import the SQL file into the phpbb installation.
Johnathan
1000+ Club
 
Posts: 1207
Joined: Thu May 31, 2007 3:28 pm
Location: Belfast, Northen Ireland

Re: How do I move data from a database into another database.

Postby webmaster on Sat Nov 29, 2008 4:52 am

Install phpMyAdmin and export the data to a .SQL-file and then import it to the other database.
User avatar
webmaster
Site Admin
 
Posts: 2695
Joined: Tue Aug 17, 2004 1:07 pm
Location: Sweden

Re: How do I move data from a database into another database.

Postby flabbyrabbit on Sat Nov 29, 2008 1:52 pm

This was the problem that I had as the database you originaly have is not going to be the same as the phpBB table. The easiest way that I found to do this was to write a php script that looped through the original table and insertered the details into the phpBB members table. The main problem I found was if the passwords being encrypted in MD5 as phpBB3 uses a different encryption, but this is easily over come.

Flabby Rabbit
Image
User avatar
flabbyrabbit
500+ Club
 
Posts: 706
Joined: Thu Jan 25, 2007 1:10 pm
Location: Midlands, England

Re: How do I move data from a database into another database.

Postby Tomi on Sat Nov 29, 2008 11:39 pm

I added you on MSN Mr Flabby Rabbit. :)
User avatar
Tomi
500+ Club
 
Posts: 925
Joined: Mon Jun 26, 2006 6:51 pm
Location: Essex, England

Re: How do I move data from a database into another database.

Postby flabbyrabbit on Sat Nov 29, 2008 11:52 pm

YAY...and i like the MR :D
Image
User avatar
flabbyrabbit
500+ Club
 
Posts: 706
Joined: Thu Jan 25, 2007 1:10 pm
Location: Midlands, England


Who is online

Users browsing this forum: No registered users and 2 guests

cron