Previous Thread
Next Thread
Print Thread
Hop To
#179344 02/24/2007 2:26 PM
Joined: Aug 2006
Posts: 583
old hand
old hand
Joined: Aug 2006
Posts: 583
Need some quicky help. I need to re-import my old threads 65 database, but I can't seem to do it with PhPadmin imort function because the DB file is too big. So, I want to to it as root user via SSH. Ok, so I have uploaded via FTP program my thread65.sql file. I have also created teh threads65 database (which is empty of course). At the command line, I know I can go to MySQL, then say MySQL> use threads65 to change to that database. But I can't remember for sure how to import my threads65.sql file inot the threads56 database. Do I just go to the directory the file is saved in then go to MySQL> use threads65, then at teh MySQL like just type the name of the script file (e.g., MySQL> threads.sql;

Or is there something more to it? It seems like last time I did this I did something like MySQL> databse user > file; but I'm note positive. I know this is simple, I just don't do it enough.

Any help would be appreciated.

Basil

Joined: Jun 2006
Posts: 9,242
Likes: 1
R
Former Developer
Former Developer
R Offline
Joined: Jun 2006
Posts: 9,242
Likes: 1
Basically, just go into the directory where you have your threads65.sql file. At that point you'd type this:

mysql threads65 < threads65.sql -u username -p

Change username to your database username. It will then prompt you for your password, and then it will import your threads65.sql file.

Joined: Jun 2006
Posts: 16,533
Likes: 150
UBB.threads Developer
UBB.threads Developer
Joined: Jun 2006
Posts: 16,533
Likes: 150
In some instances MySQL will not accept the above line due to the host parameter not being utilized, I generally use:

MySQL Export: mysqldump -uusername -ppassword database_name > backup_file.sql
MySQL Import: mysql -h localhost -uusername -ppassword database_name < backup_file.sql


I am a Web Development Contractor, I do not work for UBBCentral. I have provided free User to User Support since the beginning of these support forums.
Do you need Forum Install or Upgrade Services?
Forums: A Gardeners Forum
UBB.threads: UBBWiki, UBB Styles, UBB.Sitemaps
Longtime Supporter & Resident Post-A-Holic
VNC Web Services: Code Modifications, Upgrades, Styling, Coding Services, Disaster Recovery, and more!
Joined: Aug 2006
Posts: 583
old hand
old hand
Joined: Aug 2006
Posts: 583
Thanks guys.


Link Copied to Clipboard
ShoutChat
Comment Guidelines: Do post respectful and insightful comments. Don't flame, hate, spam.
Recent Topics
Selling a Forum?
by ECNet - 10/10/2026 10:54 AM
PHP 8 bug in membermanage.tmpl
by phoenix011235 - 09/08/2026 7:47 PM
Who's Online Now
0 members (), 298 guests, and 124 robots.
Key: Admin, Global Mod, Mod
Random Gallery Image
Latest Gallery Images
Ride safe!
Ride safe!
by Morgan, December 7
Los Angeles
Los Angeles
by isaac, August 6
3D Creations
3D Creations
by JAISP, December 30
Artistic structures
Artistic structures
by isaac, August 29
Powered by UBB.threads™ PHP Forum Software 8.1.0
(Snapshot build 20260527)