Re: No database selected error when running mysql_tzinfo_to_sql

2008-03-10 Thread Tim McDaniel
On Mon, 10 Mar 2008, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: wrote: The command worked with this syntax: root> mysql_tzinfo_to_sql /usr/share/zoneinfo/America/ | mysql -D mysql -u xxx -p xxx It's easy to know that the command ran without error, but I don't know how to test it to know tha

Re: No database selected error when running mysql_tzinfo_to_sql

2008-03-10 Thread Daniel Brown
On Mon, Mar 10, 2008 at 11:36 AM, Tim McDaniel <[EMAIL PROTECTED]> wrote: > On Mon, 10 Mar 2008, Daniel Brown <[EMAIL PROTECTED]> wrote: > >mysql -D mysql -u xxx -p < mysql_tzinfo_to_sql > /usr/share/zoneinfo/America/ > > > >The -D flag selects the database `mysql`, which is where the t

Re: No database selected error when running mysql_tzinfo_to_sql

2008-03-10 Thread dpgirago
> Its example line is > mysql_tzinfo_to_sql /usr/share/zoneinfo | mysql -u root mysql > There's a trailing "mysql", which specifies the "mysql" database. > It also specifies all zoneinfo, not "America/". Thanks, Tim. I totally missed the trailing mysql. Duh! --David.

Re: No database selected error when running mysql_tzinfo_to_sql

2008-03-10 Thread dpgirago
> On Mon, Mar 10, 2008 at 11:07 AM, <[EMAIL PROTECTED]> wrote: >> I'm getting an error trying to run this command: >> >> root> mysql_tzinfo_to_sql /usr/share/zoneinfo/America/ | mysql -u xxx -p >> xxx >> >> ERROR 1046 (3D000) at line 1: No database selected > >mysql -D mysql -u xxx -p < m

Re: No database selected error when running mysql_tzinfo_to_sql

2008-03-10 Thread Tim McDaniel
On Mon, 10 Mar 2008, Daniel Brown <[EMAIL PROTECTED]> wrote: mysql -D mysql -u xxx -p < mysql_tzinfo_to_sql /usr/share/zoneinfo/America/ The -D flag selects the database `mysql`, which is where the time zone information belongs. The < redirect reads from the "file" (which, in this case, i

Re: No database selected error when running mysql_tzinfo_to_sql

2008-03-10 Thread Tim McDaniel
On Mon, 10 Mar 2008, [EMAIL PROTECTED] wrote: I'm getting an error trying to run this command: root> mysql_tzinfo_to_sql /usr/share/zoneinfo/America/ | mysql -u xxx -p xxx ERROR 1046 (3D000) at line 1: No database selected The MySQL 5.0 manual explains mysql_tzinfo_to_sql at

Re: No database selected error when running mysql_tzinfo_to_sql

2008-03-10 Thread Daniel Brown
On Mon, Mar 10, 2008 at 11:07 AM, <[EMAIL PROTECTED]> wrote: > I'm getting an error trying to run this command: > > root> mysql_tzinfo_to_sql /usr/share/zoneinfo/America/ | mysql -u xxx -p > xxx > > ERROR 1046 (3D000) at line 1: No database selected mysql -D mysql -u xxx -p < mysql_tzinfo