Re: Command line fails mysql mydb mufile.sql

2003-10-15 Thread Nestor Florez
Did not workd, I get an error
ERROR 1045: Access denied for user: '[EMAIL PROTECTED]' (Using
password: NO)

I can log in as -u administrator when I use the -p option.  I need to
make it work
from  command line  because I am planning to put this command in 
a script to make it automatic to insert records.

Nestor :-)

Nestor A. Florez


 Tobias Asplund [EMAIL PROTECTED] 10/15/2003 12:02:21 PM 

 c:\mysql mydb  myfile.sql
 ERROR 1044: Access denied for user: '@localhost' to database 'mydb'

try mysql -u administrator mydb  myfile.sql


-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: Command line fails mysql mydb mufile.sql

2003-10-15 Thread Victoria Reznichenko
Nestor Florez [EMAIL PROTECTED] wrote:
 Help,
 
 Guys I have done this before but it is not working for me when I try to
 do some
 inserts via a file from the command line
 c:\mysql mydb  myfile.sql
 ERROR 1044: Access denied for user: '@localhost' to database 'mydb'
 
 I am logged in as administrator on my W2K and I have granted ALL
 privileges to 
 administrator and it fails:
 grant all privileges on mydb.* to [EMAIL PROTECTED] identified by
 'pwd';
 
 I even tried the following grants:
 grant all privileges on mydb.* to administrator@'%' identified by
 'pwd';
 grant all privileges on mydb.* to '%@'%' identified by 'pwd';
 
 No luck here.
 
 Any ideas?
 

You forgot to specify user name and password. You can do something like:

mysql -uadministrator -ppwd mydb  myfile.sql


-- 
For technical support contracts, goto https://order.mysql.com/?ref=ensita
This email is sponsored by Ensita.net http://www.ensita.net/
   __  ___ ___   __
  /  |/  /_ __/ __/ __ \/ /Victoria Reznichenko
 / /|_/ / // /\ \/ /_/ / /__   [EMAIL PROTECTED]
/_/  /_/\_, /___/\___\_\___/   MySQL AB / Ensita.net
   ___/   www.mysql.com





-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: Command line fails mysql mydb mufile.sql

2003-10-15 Thread Tobias Asplund

http://www.mysql.com/doc/en/Option_files.html
Check the example halfway down the page, it shows how you can supply a
password through your my.cnf file.


 I can log in as -u administrator when I use the -p option.  I need to
 make it work
 from  command line  because I am planning to put this command in
 a script to make it automatic to insert records.

 Nestor :-)

 Nestor A. Florez


  Tobias Asplund [EMAIL PROTECTED] 10/15/2003 12:02:21 PM 

  c:\mysql mydb  myfile.sql
  ERROR 1044: Access denied for user: '@localhost' to database 'mydb'

 try mysql -u administrator mydb  myfile.sql




-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: Command line fails mysql mydb mufile.sql

2003-10-15 Thread Nestor Florez
Believe it or not I tried 
mysql -p administrator -p pwd mydb  myfile.sql

and it would not worked, but when I got rid of the space it work
mysql -uadministrator -upwd mydb  myfile.sql

I did not think that the spaces after the '-u' and  the '-p' matter

Thanks,

Nestor :-)


Nestor A. Florez


 Victoria Reznichenko [EMAIL PROTECTED] 10/15/2003
12:28:24 PM 
Nestor Florez [EMAIL PROTECTED] wrote:
 Help,
 
 Guys I have done this before but it is not working for me when I try
to
 do some
 inserts via a file from the command line
 c:\mysql mydb  myfile.sql
 ERROR 1044: Access denied for user: '@localhost' to database 'mydb'
 
 I am logged in as administrator on my W2K and I have granted ALL
 privileges to 
 administrator and it fails:
 grant all privileges on mydb.* to [EMAIL PROTECTED] identified
by
 'pwd';
 
 I even tried the following grants:
 grant all privileges on mydb.* to administrator@'%' identified by
 'pwd';
 grant all privileges on mydb.* to '%@'%' identified by 'pwd';
 
 No luck here.
 
 Any ideas?
 

You forgot to specify user name and password. You can do something
like:

mysql -uadministrator -ppwd mydb  myfile.sql


-- 
For technical support contracts, goto
https://order.mysql.com/?ref=ensita 
This email is sponsored by Ensita.net http://www.ensita.net/ 
   __  ___ ___   __
  /  |/  /_ __/ __/ __ \/ /Victoria Reznichenko
 / /|_/ / // /\ \/ /_/ / /__   [EMAIL PROTECTED] 
/_/  /_/\_, /___/\___\_\___/   MySQL AB / Ensita.net
   ___/   www.mysql.com 





-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql 
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: Command line fails mysql mydb mufile.sql

2003-10-15 Thread Paul DuBois
At 13:15 -0700 10/15/03, Nestor Florez wrote:
Believe it or not I tried
mysql -p administrator -p pwd mydb  myfile.sql
and it would not worked, but when I got rid of the space it work
Yes, that's how it's supposed to work:

http://www.mysql.com/doc/en/mysql.html

mysql -uadministrator -upwd mydb  myfile.sql

I did not think that the spaces after the '-u' and  the '-p' matter
It doesn't for other options.  -p is special, because if you leave
out the password value, that's how mysql knows you want to be prompted
interactively for the password.
Thanks,

Nestor :-)

Nestor A. Florez


--
Paul DuBois, Senior Technical Writer
Madison, Wisconsin, USA
MySQL AB, www.mysql.com
Are you MySQL certified?  http://www.mysql.com/certification/

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]