Renaming a database?

2011-05-24 Thread Jerry Schwartz
It looks like there’s no way to rename a database. Is that true? I have two reasons for wanting to do this: - I want to get a current version of a database out of the way so that I can load in an older version, without having to pay the penalty of reloading the current version. - I

Re: Renaming a database?

2011-05-24 Thread Andrew Moore
Instead of renaming it, revoke permissions to it. If it's being used you should see some problems in the application due to access denied. Andy On Tue, May 24, 2011 at 4:19 PM, Jerry Schwartz je...@gii.co.jp wrote: It looks like there’s no way to rename a database. Is that true? I have two

Re: Renaming a database?

2011-05-24 Thread Johan De Meersman
- Original Message - From: Jerry Schwartz je...@gii.co.jp It looks like there’s no way to rename a database. Is that true? Yes. Silly oversight, although there's probably complexity reasons behind it. - I want to get a current version of a database out of the way so that I can load

RE: Renaming a database?

2011-05-24 Thread Jerry Schwartz
-Original Message- From: Johan De Meersman [mailto:vegiv...@tuxera.be] Sent: Tuesday, May 24, 2011 11:52 AM To: Jerry Schwartz Cc: mysql@lists.mysql.com Subject: Re: Renaming a database? - Original Message - From: Jerry Schwartz je...@gii.co.jp It looks like there's no way

RE: Renaming a database?

2011-05-24 Thread Jerry Schwartz
-Original Message- From: Andrew Moore [mailto:eroomy...@gmail.com] Sent: Tuesday, May 24, 2011 11:31 AM To: Jerry Schwartz Cc: mysql@lists.mysql.com Subject: Re: Renaming a database? Instead of renaming it, revoke permissions to it. If it's being used you should see some problems

Re: Renaming a database?

2011-05-24 Thread Andrew Moore
Could you try restoring the other db with another name and changing the connection string in the app? On 24 May 2011 16:20, Jerry Schwartz je...@gii.co.jp wrote: It looks like there’s no way to rename a database. Is that true? I have two reasons for wanting to do this: - I want to get a

RE: Renaming a database?

2011-05-24 Thread Jerry Schwartz
From: Andrew Moore [mailto:eroomy...@gmail.com] Sent: Tuesday, May 24, 2011 2:56 PM To: Jerry Schwartz Cc: mysql@lists.mysql.com Subject: Re: Renaming a database? Could you try restoring the other db with another name and changing the connection string in the app? [JS] I could

RE: Renaming a database?

2011-05-24 Thread Daevid Vincent
-Original Message- On Tue, May 24, 2011 at 4:19 PM, Jerry Schwartz je...@gii.co.jp wrote: It looks like there’s no way to rename a database. Is that true? I know. Retarded right? Version 5.1.x and still what would seem the most basic of tasks is still impossible. Maybe Oracle can

Re: Renaming a Database

2009-08-19 Thread Matt Neimeyer
That said... Is there anything wrong (dangerous, disasterous, etc) with stopping the MySQL service and renaming the folder in the MySQL data folder? By my logic (if I'm right) this should preserve any permissions on the folder and since the service is stopped it should simply find the new

RE: Renaming a Database

2009-08-19 Thread Rolando Edwards
: RolandoLogicWorx redwa...@logicworks.net -Original Message- From: Matt Neimeyer [mailto:m...@neimeyer.org] Sent: Wednesday, August 19, 2009 9:27 AM To: Paul DuBois Cc: mysql@lists.mysql.com Subject: Re: Renaming a Database That said... Is there anything wrong (dangerous, disasterous, etc

Re: Renaming a Database

2009-08-19 Thread Matt Neimeyer
Skype : RolandoLogicWorx redwa...@logicworks.net -Original Message- From: Matt Neimeyer [mailto:m...@neimeyer.org] Sent: Wednesday, August 19, 2009 9:27 AM To: Paul DuBois Cc: mysql@lists.mysql.com Subject: Re: Renaming a Database That said... Is there anything wrong (dangerous

Renaming a Database

2009-08-17 Thread Matt Neimeyer
I know the best way to rename a database is to use mysqldump, extract the database and then reload to the new database. (At least based on what I can find in the 12.1.32. RENAME DATABASE Syntax section of the documentation) That said... Is there anything wrong (dangerous, disasterous, etc) with

Re: Renaming a Database

2009-08-17 Thread Paul DuBois
On Aug 17, 2009, at 4:22 PM, Matt Neimeyer wrote: I know the best way to rename a database is to use mysqldump, extract the database and then reload to the new database. (At least based on what I can find in the 12.1.32. RENAME DATABASE Syntax section of the documentation) That said... Is

Re: renaming the database

2005-10-17 Thread Jigal van Hemert
Octavian Rasnita wrote: Is there a command for renaming a MySQL database? Sorry, there is no command for that. For small databases you can use administration tools like phpMyAdmin, etc. which will do it for you by duplicating the database structure and data, and then drop the 'old' database

Re: renaming the database

2005-10-17 Thread Octavian Rasnita
PROTECTED] Cc: mysql@lists.mysql.com Sent: Monday, October 17, 2005 12:11 PM Subject: Re: renaming the database Octavian Rasnita wrote: Is there a command for renaming a MySQL database? Sorry, there is no command for that. For small databases you can use administration tools like phpMyAdmin, etc

Re: renaming the database

2005-10-17 Thread C.R. Vegelin
, 2005 12:11 PM Subject: Re: renaming the database Octavian Rasnita wrote: Is there a command for renaming a MySQL database? Sorry, there is no command for that. For small databases you can use administration tools like phpMyAdmin, etc. which will do it for you by duplicating the database

Re: renaming the database

2005-10-17 Thread Jigal van Hemert
C.R. Vegelin wrote: What about renaming the folder indicating the database name. I work with Windows XP and renaming a folder works well. Cor, Have you tried it with InnoDB tables or anything other than MyISAM tables? InnoDB uses a single tablespace per server (unless specified that it

Re: renaming the database

2005-10-17 Thread Robert L Cochran
to that.) Based on the documentation the database name is simply a directory name, no more and no less. Renaming tables has its own command syntax, you can look it up. Bob Cochran Octavian Rasnita wrote: Hi, Is there a command for renaming a MySQL database? Thank you. Teddy -- MySQL

Re: renaming the database

2005-10-17 Thread SGreen
, Is there a command for renaming a MySQL database? Thank you. Teddy The only way I have done it has been to create an empty database with the name I want. Then I used RENAME TABLE to move all of the tables into the new database. Sure it takes a lot of RENAME TABLE statements

Re: renaming the database

2005-10-17 Thread Robert L Cochran
its own command syntax, you can look it up. Bob Cochran Octavian Rasnita wrote: Hi, Is there a command for renaming a MySQL database? Thank you. Teddy The only way I have done it has been to create an empty database with the name I want. Then I used RENAME TABLE to move

Re: renaming the database

2005-10-17 Thread SGreen
the database name is simply a directory name, no more and no less. Renaming tables has its own command syntax, you can look it up. Bob Cochran Octavian Rasnita wrote: Hi, Is there a command for renaming a MySQL database? Thank you. Teddy The only way I

Re: renaming the database

2005-10-17 Thread Gleb Paharenko
Hello. This is a frequently asked question. See: http://lists.mysql.com/mysql/188094 For more solutions search in the archives at: http://lists.mysql.com Octavian Rasnita wrote: Hi, Is there a command for renaming a MySQL database? Thank you. Teddy

Re: renaming the database

2005-10-17 Thread Peter Brawley
tory name, no more and no less. Renaming tables has its own command syntax, you can look it up. Bob Cochran Octavian Rasnita wrote: Hi, Is there a command for renaming a MySQL database? Thank you. Teddy The only way I have done it has been to create an em

Re: renaming the database

2005-10-17 Thread Peter Brawley
Errm, needed to take the grants table updates out of the repat loop: CREATE PROCEDURE RenameDatabase (IN oldname CHAR(64), IN newname CHAR(64)) BEGIN DECLARE sname CHAR(64) DEFAULT NULL; DECLARE rows INT DEFAULT 1; DECLARE total INT DEFAULT 0; CREATE DATABASE IF NOT EXISTS newname; REPEAT

renaming the database

2005-10-16 Thread Octavian Rasnita
Hi, Is there a command for renaming a MySQL database? Thank you. Teddy -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]

Re: renaming a database

2005-08-22 Thread Gleb Paharenko
Hello. One possible solution is to create a new database, and then RENAME TABLE each table from the original database into the new database. Then drop the original database. Octavian Rasnita [EMAIL PROTECTED] wrote: Hi, Please tell me how to rename a database. I couldn't find this

renaming a database

2005-08-21 Thread Octavian Rasnita
Hi, Please tell me how to rename a database. I couldn't find this in the manual. I have tried to rename manually the name of the directory that holds that database, but some tables can't be accessed after that. (I have found that they are InnoDB tables, even though I never specified that I want

Re: renaming a database

2005-08-21 Thread Peter Brawley
Octavian Please tell me how to rename a database. As you already found, there are database features that don't survive renaming its directory. Best method I know is to mysqldump it and recreate it from the dump under the desired name. PB http://www.artfulsoftware.com - Octavian

Renaming a database

2005-07-18 Thread Scott Hamm
How do I rename a database? The help online is pretty ambigous. -- Power to people, Linux is here.

Re: Renaming a database

2005-07-18 Thread SGreen
Scott Hamm [EMAIL PROTECTED] wrote on 07/18/2005 12:01:49 PM: How do I rename a database? The help online is pretty ambigous. -- Power to people, Linux is here. I wouldn't say ambiguous. I would rather say indirect. Renaming a database is nearly the same thing as moving tables to a new

RE: Renaming a database

2005-07-18 Thread Gordon Bruce
- From: Scott Hamm [mailto:[EMAIL PROTECTED] Sent: Monday, July 18, 2005 11:02 AM To: 'Mysql ' Subject: Renaming a database How do I rename a database? The help online is pretty ambigous. -- Power to people, Linux is here.

**newbie question** renaming a database

2004-10-07 Thread Carolina
using mysql version 4.0.13 - **total newbie here**... something as simple as renaming a database...i've not found anything relating to that on the mysql site or anywhere else. what i have found is that in order to do this, i'd have to shutdown and restart the mysql database in order to do

Re: **newbie question** renaming a database

2004-10-07 Thread gerald_clark
Carolina wrote: using mysql version 4.0.13 - **total newbie here**... something as simple as renaming a database...i've not found anything relating to that on the mysql site or anywhere else. what i have found is that in order to do this, i'd have to shutdown and restart the mysql database

Re: **newbie question** renaming a database

2004-10-07 Thread Paul DuBois
At 11:16 -0500 10/7/04, gerald_clark wrote: Carolina wrote: using mysql version 4.0.13 - **total newbie here**... something as simple as renaming a database...i've not found anything relating to that on the mysql site or anywhere else. what i have found is that in order to do this, i'd have

renaming a database

2002-01-30 Thread JC
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 I'm kind of interested to find if there is a way to rename a database with something like the alter command. Looking in the index of the New Riders MySQL book I don't see anything other than renaming tables Looking through the Manual for version 3

Re: renaming a database

2002-01-30 Thread Paul DuBois
At 11:10 -0800 1/30/02, JC wrote: -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 I'm kind of interested to find if there is a way to rename a database with something like the alter command. Looking in the index of the New Riders MySQL book I don't see anything other than renaming tables Looking

Re: renaming a database

2002-01-30 Thread Nathan
system. # Nathan - Original Message - From: JC [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Wednesday, January 30, 2002 12:10 PM Subject: renaming a database -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 I'm kind of interested to find if there is a way to rename a database with something

Re[2]: renaming a database

2002-01-30 Thread Dmitry Alyabyev
What would I do if there are InnoDB tables ? -- Dimitry Wednesday, January 30, 2002, 9:31:09 PM, Paul DuBois wrote: At 11:10 -0800 1/30/02, JC wrote: -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 I'm kind of interested to find if there is a way to rename a database with something like the

RE: renaming a database

2001-11-11 Thread Heikki Tuuri
Hi! Can you rename a database? If so, how does it handle all the tables inside it? By shutting down the server, renaming the directory of that database and restarting the server. The server will be able to handle the change just fine. Sorry, but InnoDB tables do not get renamed inside

renaming a database

2001-11-10 Thread Corey Kaye
Can you rename a database? If so, how does it handle all the tables inside it? Thanks. - Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list

RE: renaming a database

2001-11-10 Thread Carsten H. Pedersen
Can you rename a database? If so, how does it handle all the tables inside it? By shutting down the server, renaming the directory of that database and restarting the server. The server will be able to handle the change just fine. / Carsten -- Carsten H. Pedersen keeper and maintainer of

Renaming a database

2001-03-19 Thread Marko Milutinovi
Hi! I'm running MySQL on Win NT 4. I'm trying to rename a database from my (Delphi) program, but I haven't found any inforamtion about this on the MySQL site. Can anybody help me? P.S.: Can a database named 2001 be created? regards, m@rko