SitePoint Sponsor |
|
User Tag List
Results 1 to 20 of 20
Thread: Transfering a MySQL database
-
Apr 27, 2004, 09:32 #1
- Join Date
- Feb 2004
- Location
- Midsouth
- Posts
- 1,373
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
Transfering a MySQL database
This may be an easy and maybe even silly question indeed, but i have to ask it anyway. i have *moderate* mysql experience, and what i mean by that is i know how to create and alter tables, and i can put stuff in them and get stuff out, no prob. im much more used to access, and for most of my projects, access works just fine.
heres my question though. with access, i have an mdb file that i just move from development to production and it works. do i have that same kind of file with mysql? or do i have to connect the two servers or something? is this what replication is for or is that just backup?
this may be newbie questions, ill admit, but the documentation isnt very clear.
Thanks in advance,
markrynoguill
Ryan Guill, AKA Mark Roman
-
Apr 27, 2004, 10:50 #2
- Join Date
- Feb 2003
- Location
- Slave I
- Posts
- 23,424
- Mentioned
- 2 Post(s)
- Tagged
- 1 Thread(s)
you'll need to do a mysql dump: http://dev.mysql.com/doc/mysql/en/mysqldump.html
-
Apr 27, 2004, 17:15 #3
- Join Date
- Apr 2004
- Location
- Arlington VA
- Posts
- 2,094
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
if you have phpmyadmin running on both machines you can just do an export. ask it to save as a text file, it will contain all the SQL to rebuild the database.
then just past the text(or pick the file) into the SQL windows on the remote copy of phpmyadmin.
-
Apr 28, 2004, 06:11 #4
- Join Date
- Feb 2004
- Location
- Midsouth
- Posts
- 1,373
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
Originally Posted by JRMillion
rynoguill
Ryan Guill, AKA Mark Roman
-
Apr 28, 2004, 06:37 #5
- Join Date
- Jul 2002
- Location
- Toronto, Canada
- Posts
- 39,347
- Mentioned
- 63 Post(s)
- Tagged
- 3 Thread(s)
mysql-front
absolutely gorgeous app
price is good, too
does a dump as easy as you please
contents look like this:
Code:# MySQL-Front Dump 2.5 # # Host: database.example.com Database: testmetodeath # -------------------------------------------------------- # Server version 4.0.16-standard-log # # Table structure for table 'orderbydemo' # CREATE TABLE orderbydemo ( foo int(11) default NULL, bar int(11) default NULL, SequenceOrder int(11) default NULL ) TYPE=MyISAM; # # Dumping data for table 'orderbydemo' # INSERT INTO orderbydemo VALUES("302", "402", "100012"); INSERT INTO orderbydemo VALUES("703", "802", "100009"); INSERT INTO orderbydemo VALUES("903", "801", "100006"); INSERT INTO orderbydemo VALUES("303", "702", "100011"); INSERT INTO orderbydemo VALUES("604", "903", "100012"); INSERT INTO orderbydemo VALUES("101", "808", "100008"); INSERT INTO orderbydemo VALUES("202", "303", "100004"); INSERT INTO orderbydemo VALUES("306", "702", "100010"); INSERT INTO orderbydemo VALUES("307", "802", "100013"); INSERT INTO orderbydemo VALUES("206", "905", "100005");
-
Apr 28, 2004, 06:45 #6
- Join Date
- Feb 2004
- Location
- Midsouth
- Posts
- 1,373
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
ill look into that rudy, but is there anything else you know of thats free?
and just for conversations sake, if i was going to do this from the comand line, or the old fashioned way, how do you even go about doing this?rynoguill
Ryan Guill, AKA Mark Roman
-
Apr 28, 2004, 06:55 #7
- Join Date
- Jul 2002
- Location
- Toronto, Canada
- Posts
- 39,347
- Mentioned
- 63 Post(s)
- Tagged
- 3 Thread(s)
what's a command line?
-
Apr 28, 2004, 07:09 #8
- Join Date
- Feb 2004
- Location
- Midsouth
- Posts
- 1,373
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
Originally Posted by r937
rynoguill
Ryan Guill, AKA Mark Roman
-
Apr 28, 2004, 12:03 #9
- Join Date
- Feb 2004
- Location
- Midsouth
- Posts
- 1,373
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
i did it just like this:
Code:mysqldump --opt [db_name] | mysql --host=[RemoteServerIPAddress] --user=[username] --password=[password] -C [db_name]
is there a better way anyone?rynoguill
Ryan Guill, AKA Mark Roman
-
May 2, 2004, 14:47 #10
- Join Date
- Jun 2003
- Location
- ether
- Posts
- 4,497
- Mentioned
- 1 Post(s)
- Tagged
- 0 Thread(s)
If you have MySQL on your webserver, then you must've got phpMyAdmin or something like that to manage your MySQL databases through browser.
And if that's the case, then it must've some sort of export or dump option. phpMyAdmin has it by name of EXPORT. Its a tab on the top.Our lives teach us who we are.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Me - Photo Blog - Personal Blog - Dev Blog
iG:Syntax Hiliter -- Colourize your code in WordPress!!
-
May 2, 2004, 14:56 #11
- Join Date
- Jul 2002
- Location
- Toronto, Canada
- Posts
- 39,347
- Mentioned
- 63 Post(s)
- Tagged
- 3 Thread(s)
Originally Posted by Rynoguill
i don't have a command line on my computer
just keyboard, mouse, and monitor
-
May 2, 2004, 14:59 #12
- Join Date
- Jun 2003
- Location
- ether
- Posts
- 4,497
- Mentioned
- 1 Post(s)
- Tagged
- 0 Thread(s)
Our lives teach us who we are.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Me - Photo Blog - Personal Blog - Dev Blog
iG:Syntax Hiliter -- Colourize your code in WordPress!!
-
May 3, 2004, 06:43 #13
- Join Date
- Feb 2004
- Location
- Midsouth
- Posts
- 1,373
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
Originally Posted by asp_funda
lol rudy, so are you saying you never do anything from the command line?rynoguill
Ryan Guill, AKA Mark Roman
-
May 3, 2004, 06:53 #14
- Join Date
- Jul 2002
- Location
- Toronto, Canada
- Posts
- 39,347
- Mentioned
- 63 Post(s)
- Tagged
- 3 Thread(s)
yes, that's what i'm saying
i don't have a command line
-
May 3, 2004, 12:12 #15
- Join Date
- Jun 2003
- Location
- ether
- Posts
- 4,497
- Mentioned
- 1 Post(s)
- Tagged
- 0 Thread(s)
Originally Posted by Rynoguill
I think you have the latter case.
Anyway, you need to have PHP to get phpMyAdmin working. PHP is free & available at www.php.net. Also, if you have second thoughts about installing it, I suggest you look for some kind of MySQL database management script in ColdFusion(I guess that you have it installed). Try at www.sourceforge.net, its the first place to look for Open Source scripts & phpMyAdmin is also available there. Then your next stop should be www.freshmeat.net.
Or look at HotScripts & then try Google.Our lives teach us who we are.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Me - Photo Blog - Personal Blog - Dev Blog
iG:Syntax Hiliter -- Colourize your code in WordPress!!
-
May 3, 2004, 12:41 #16
- Join Date
- Feb 2004
- Location
- Midsouth
- Posts
- 1,373
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
right, its unmanaged, i have full control, its basicly my computer. and honstly, i really dont want to put php on it just yet, mainly cause i really dont know much about it and dont have a need for it.
ill just stick with my command from the command line.rynoguill
Ryan Guill, AKA Mark Roman
-
May 4, 2004, 11:31 #17
- Join Date
- Jun 2003
- Location
- ether
- Posts
- 4,497
- Mentioned
- 1 Post(s)
- Tagged
- 0 Thread(s)
as far as I know, you have full control on managed
dedicated servers too, they are your computers too.
The fact is that managed solutions are expensive than
unmanaged ones, b'coz you are charged the
maintenance costs.
Well, as you don't want to install PHP, you can look into some
ColdFusion equivalent of phpMyAdmin. I found javaMyAdmin &
jspMyAdmin for MySQL at SourceForge.net, so maybe you can
find cfMyAdmin or coldfusionMyAdmin, something done in CF to
manage MySQL.Our lives teach us who we are.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Me - Photo Blog - Personal Blog - Dev Blog
iG:Syntax Hiliter -- Colourize your code in WordPress!!
-
May 4, 2004, 12:35 #18
- Join Date
- Jul 2002
- Location
- Toronto, Canada
- Posts
- 39,347
- Mentioned
- 63 Post(s)
- Tagged
- 3 Thread(s)
i'm using mysql-front on my desktop to manage my mysql database in phoenix arizona
and if you knew how clumsy i am when it comes to installing software, that's saying a lot right there, that i was able to install it and connect it to the right port and everything (heck, i don't hardly even know what ports are)
-
May 5, 2004, 06:57 #19
- Join Date
- Feb 2004
- Location
- Midsouth
- Posts
- 1,373
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
Originally Posted by r937
rynoguill
Ryan Guill, AKA Mark Roman
-
May 5, 2004, 12:14 #20
- Join Date
- Jul 2002
- Location
- Toronto, Canada
- Posts
- 39,347
- Mentioned
- 63 Post(s)
- Tagged
- 3 Thread(s)
any time
Bookmarks