[PHP] Re: mysqldump

2003-02-27 Thread Niels Andersen
There mey, but need not be a space. As far as I know, the option scanner in
mysqldump ignores spaces between short options and their values.


John Taylor-Johnston [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
 Thanks!

  exec(mysqldump -c -q database -u user -ppassword, $sql);

 Why is there no space between the -p and password?

 -ppassword

 Am I wrong?

 Thanks,
 John




-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] RE: mysqldump

2003-02-27 Thread Uttam
snip from manual for -p option:

|-

-p[password], --password[=...]

Password to use when connecting to server. If a password is not given on the
command line, you will be prompted for it.  Note that if you use the short
form -p you can't have a space between the option and the password.

-|

regds,
-Original Message-
From: Niels Andersen [mailto:[EMAIL PROTECTED]
Sent: Thursday, February 27, 2003 16:09
To: [EMAIL PROTECTED]
Subject: Re: mysqldump


There mey, but need not be a space. As far as I know, the option scanner
in
mysqldump ignores spaces between short options and their values.


John Taylor-Johnston [EMAIL PROTECTED] wrote in
message
news:[EMAIL PROTECTED]
 Thanks!

  exec(mysqldump -c -q database -u user -ppassword, $sql);

 Why is there no space between the -p and password?

 -ppassword

 Am I wrong?

 Thanks,
 John





-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Re: mysqldump

2003-02-27 Thread Tom Rogers
Hi,

Thursday, February 27, 2003, 2:55:48 PM, you wrote:
JTJ Thanks!

 exec(mysqldump -c -q database -u user -ppassword, $sql);

JTJ Why is there no space between the -p and password?

-ppassword

JTJ Am I wrong?

JTJ Thanks,
JTJ John

Probably because a space is a valid char in password

-- 
regards,
Tom


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Re: mysqldump

2003-02-26 Thread Joseph Szobody
You need to use exec, system, etc. Here is a script that I recently put together. It 
backs up the database, and pushes it as a download to the user.

?php
$filename = db_backup_ . date(n-j-y);
header(Content-Disposition: filename=$filename.sql);
header(Content-Type: application/force-download);

exec(mysqldump -c -q user -u webserver -ppassword, $sql);

for($i = 0; $i  count($sql); $i++) {
 echo $sql[$i] . \r\n;
}
?

Hope this helps,

Joseph

John Taylor-Johnston [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED]
 Anyone do MySQLDump using PHP ?
 
 http://www.mysql.com/doc/en/mysqldump.html
 
 My code is:
 mysqldump -u ** -p ** -A  /home/mybackups/dump_all.sql
 
 I would like to pull it off using PHP, remotely.
 
 $date = date (Ymd);
 $to_path = /home/MyBackups/$date/dump_all.sql;
 
 mysqldump -u ** -p ** -A  $to_path;
 
 mysqldump is not PHP?!
 
 John
 


--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Re: mysqldump

2003-02-26 Thread Joseph Szobody
u. that should read:

exec(mysqldump -c -q database -u user -ppassword, $sql);



--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Re: mysqldump

2003-02-26 Thread John Taylor-Johnston
Thanks!

 exec(mysqldump -c -q database -u user -ppassword, $sql);

Why is there no space between the -p and password?

-ppassword

Am I wrong?

Thanks,
John


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Re: Mysqldump

2002-10-06 Thread Paul Nicholson

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Hey,
I'm not sure about windows machines as I use linux but it looks like you're 
sending the right commands. You need to check your permissions.
~Paul

On Sunday 06 October 2002 12:30 am, Uma Shankari T. wrote:
 Hello,

   I am trying to dump the text file contents to mysql which was already
 backup from mysql only..While trying to dump it is telling access denied
 error

  i am trying from here

  d:\mysql\binmysqldump databasename txt.file name

 Can anyone tell me how to go about with this ??

 Regards,
 Uma

- -- 
~Paul Nicholson
Design Specialist @ WebPower Design
The webthe way you want it!
[EMAIL PROTECTED]

It said uses Windows 98 or better, so I loaded Linux!
Registered Linux User #183202 using Register Linux System # 81891
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.0.6 (GNU/Linux)
Comment: For info see http://www.gnupg.org

iD8DBQE9oFpTDyXNIUN3+UQRAq7wAJ97jRHEUq/oQivyZzHD22wpQegbZwCdGeTl
Sux8I5NCDdbJk9lstKeKsr8=
=dwjM
-END PGP SIGNATURE-

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php