On Tue, Jul 23, 2002 at 11:59:43AM -0400, denonymous wrote:
> From: "Gerald Clark" <[EMAIL PROTECTED]>
> 
> > Why do think this should not be an error?
> > If you were writing a script, would you not want to know you had made
> > the error?
> > Just how many , or how severe should  errors be before you are notified?
> 
> 
> The ability to run more than one query on one line is a feature, not a bug.
> An empty semicolon is a badly-formed query. It's perfectly logical for the
> interpreter to spot two semi-colons as a badly-formed query and call an
> error for it.
> 
> As far as a scripted environment goes...
> 
> If you're referring to Perl or something similar, it's not a common
> occurance to run more than one query in the same query() function;
> therefore, no semi-colon is required by the coder, which voids the
> possibility of accidentally adding a second semi-colon.

I quite agree that to have more than one command on a line is a nice thing.

What I am saying is that barfing on an empty command is not the right thing to do.
I remember, many years ago, I wrote some coding standards where I said:

        Every program/function should do nothing correctly.

(think about it before replying).

-- 
Alain Williams

#include <std_disclaimer.h>

---------------------------------------------------------------------
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/           (the list archive)

To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

Reply via email to