Return to iWEBTOOL

Go Back   iWEBTOOL Talk > The Web and your Website > Programming > PHP > MySQL
Register FAQ Members List Calendar Search Today's Posts Mark Forums Read
 
Welcome to iWEBTOOL Talk, where you talk about webmaster-related stuff.
 
Discuss topics which interest you.
With over thousands of threads (topics), we're sure you'll find something that'll interest you.
Ask for help whenever you need it.
We have thousands of members who are available to help you if you need it.
It's absolutely FREE!

 1  Register           2  Browse the board           3  Discuss whatever may interest you!
 


Closed Thread
 
Thread Tools Search this Thread Display Modes
Old 01-28-2007, 04:58 AM   #1
pakadtrader
Junior Member
 
pakadtrader's Avatar
 
Join Date: Oct 2006
Posts: 11
pakadtrader will become famous soon enough
Default Change DB Name

Hi Friends,

I want to change DB name in MySQL but dont know how. Please help me.
pakadtrader is offline  
 
This is an Ad Revenue Sharing forum Place your advert here
SEO Checklist
Get yourself better ranking with
our "Do-it-Yourself" SEO Checklist.
Click Here
Old 01-28-2007, 05:35 AM   #2
jumpenjuhosaphat
 Contributor 
 
jumpenjuhosaphat's Avatar
 
Join Date: Jun 2006
Location: Denver
Posts: 4,459
jumpenjuhosaphat has much to be proud ofjumpenjuhosaphat has much to be proud ofjumpenjuhosaphat has much to be proud ofjumpenjuhosaphat has much to be proud ofjumpenjuhosaphat has much to be proud ofjumpenjuhosaphat has much to be proud ofjumpenjuhosaphat has much to be proud ofjumpenjuhosaphat has much to be proud of
Default Re: Change DB Name

If you have phpmyadmin, you can change the name of the table by clicking on the table you want changed, then clicking on the operations tab. Enter the new name of your table and click go.

If you need to script it, or don't have phpmyadmin, use

Code:
RENAME TABLE oldname TO newname
__________________
Storage Sheds
Lost Forum
jumpenjuhosaphat is offline  
Old 01-28-2007, 08:39 AM   #3
pakadtrader
Junior Member
 
pakadtrader's Avatar
 
Join Date: Oct 2006
Posts: 11
pakadtrader will become famous soon enough
Default Re: Change DB Name

I know how to rename table name. I want to change DB NAME
pakadtrader is offline  
Old 01-28-2007, 08:43 AM   #4
midlandi
iWEBTOOL Moderator
 Contributor 
 
midlandi's Avatar
 
Join Date: Oct 2006
Posts: 2,196
midlandi is just really nicemidlandi is just really nicemidlandi is just really nicemidlandi is just really nicemidlandi is just really nice
Default Re: Change DB Name

Do you have Cpanel?
midlandi is offline  
Old 01-28-2007, 10:01 AM   #5
pakadtrader
Junior Member
 
pakadtrader's Avatar
 
Join Date: Oct 2006
Posts: 11
pakadtrader will become famous soon enough
Default Re: Change DB Name

Yes, I have Cpanel.
pakadtrader is offline  
Old 02-09-2007, 07:40 PM   #6
ForumJoiner
Newcomer
 
ForumJoiner's Avatar
 
Join Date: Feb 2007
Posts: 9
ForumJoiner is on a distinguished road
Default Re: Change DB Name

Let's say it's a local database. The database's name is actually the folder's name in which the database is stored. Change that folder's name with Explorer (if you have Windows) and that's it.

For mysql, the folder where all the databases are is:
mysql\data
(that is, the "data" subfolder of MySQL folder.

Make an experiment. Create a database using mysql command prompt. You'll see that "create database" actually creates an emplty folder on the data folder.
ForumJoiner is offline  
Old 02-09-2007, 07:56 PM   #7
jumpenjuhosaphat
 Contributor 
 
jumpenjuhosaphat's Avatar
 
Join Date: Jun 2006
Location: Denver
Posts: 4,459
jumpenjuhosaphat has much to be proud ofjumpenjuhosaphat has much to be proud ofjumpenjuhosaphat has much to be proud ofjumpenjuhosaphat has much to be proud ofjumpenjuhosaphat has much to be proud ofjumpenjuhosaphat has much to be proud ofjumpenjuhosaphat has much to be proud ofjumpenjuhosaphat has much to be proud of
Default Re: Change DB Name

You can do that using phpmyadmin as well. If not:
RENAME TABLE thisname TO thatname

Check out the reference at http://dev.mysql.com/doc/refman/5.0/...ame-table.html
__________________
Storage Sheds
Lost Forum
jumpenjuhosaphat is offline  
 
This is an Ad Revenue Sharing forum Place your advert here
Webmaster Tools Webmaster Tools Click Here
Closed Thread

(Threads which have no activity for more than 30 days are automatically closed.)



Quick Reply
Message:

Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
How Often do you change your webhosts pairbrother Web Hosting 29 03-28-2007 11:55 AM
Backlinks And PR Change Kirtan Link Building 14 02-01-2007 12:06 AM
Request Name Change UnKnown Help and Support 6 11-23-2006 03:38 PM
Should i change... King Gareth Domain Name 4 01-09-2006 08:33 PM


All times are GMT. The time now is 11:58 PM.


Powered by vBulletin v3.6.7 © 2008, Jelsoft Enterprises Ltd. SEO by vBSEO © 2006, Crawlability, Inc.