Hi Rithish,
Thank you all for your suggestion, I would definitely give it a shot.
Regards,
Ryan.
On 3/13/06, Rithish Saralaya <rithish.saralaya@stripped> wrote:
>
> Hello Ryan. I am more of a developer than a MySQL administrator. Hence, I
> would always favour applications logging query errors rather than being
> dependent on MySQL to generate a log for me. Of course, I may be wrong.
>
> You could write a query execution function, say exec_mysql_query(...) in
> one
> of you files, say 'Db.inc' and have it included in all your files.
>
> exec_mysql_query(...) will log all mysql errors into a file. and you may
> provide an web-interface (assuming this is a web application) to
> view/download the log files.
>
> Regards,
> Rithish.
>
>
>
> -----Original Message-----
> From: ryan lwf [mailto:ryanlwf@stripped]
> Sent: Friday, March 10, 2006 8:14 PM
> To: Dan Nelson
> Cc: mysql@stripped
> Subject: Re: How to Log Warnings and Errors from queries
>
>
> Hi Dan,
>
> Noted with thanks.
>
> As such, is there a workaround to log problematic sql queries ran against
> the mysqld server ? Do I need to write separate script to do this ?
>
> Regards,
> Ryan.
>
> On 3/10/06, Dan Nelson <dnelson@stripped> wrote:
> >
> > In the last episode (Mar 08), ryan lwf said:
> > > I understand that the option log-errors and log-warnings only logs
> > > server related internal errors. How do I enable logging errors from
> > > queries executed, so that I can fix the problematic query statement
> > > accordingly?
> > >
> > > The statement "SHOW WARNINGS" and "SHOW ERRORS" does not work on my
> > > server with mysqld-4.0.25 binary version.
> >
> > Those commands appeared in MySQL 4.1. Before then, warnings were
> > simply counted.
> >
> > --
> > Dan Nelson
> > dnelson@stripped
> >
>
>