PDA

View Full Version : MySQL/PHP problem


exasko
08-22-03, 02:13 PM
I have been self-teaching myself MySQL and PHP. Earlier tonight I contacted my hosting company with a problem. As I worked through the examples in the text, I wanted to use my web site to test them out. However, from their response, I found that this was going to be a problem.

They told me that I could not build the database on my own machine and then transfer the raw MySQL database files and the PHP script to connect to it to my account because I do not have "access permissions to the MySQL data directory".

You can imagine my frustration when they told me to use the mysqldump utility to dump my existing db into a text file, build the database on the server through Cpanel, and then input my data back in.

Is there a better or more flexible way to do this? Was I naive to think that I could build a database on my pc and then transfer the raw files to a server? Is this standard practice with hosting companies? Anyone who could offer any tips or information would deserve my gratitude and appreciation.

Please remember though, I'm still learning and am still a neophyte in this game......so the simpler the explanation, the better.

Thanks.

S3G
08-22-03, 02:41 PM
You can imagine my frustration when they told me to use the mysqldump utility to dump my existing db into a text file, build the database on the server through Cpanel, and then input my data back in.

That way is the generally accepted way to do it and is how database backups are generally stored (with compression maybe)

If you're using cPanel you could also copy and paste the raw SQL into phpMyAdmin.

They told me that I could not build the database on my own machine and then transfer the raw MySQL database files and the PHP script to connect to it to my account because I do not have "access permissions to the MySQL data directory".

Which is a good thing or else everybody could look at you database and vice-versa :)

Hope this helps.

exasko
08-22-03, 04:23 PM
Thanks for your help and your patience

weblord
09-26-03, 04:37 AM
cpanel can create unlimited databases for you usually with your webhosting provider