----- Original Message -----
From: "Paul DuBois" <[EMAIL PROTECTED]>
To: "Mark" <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>
Sent: Friday, May 10, 2002 6:09 PM
Subject: Re: Qoute


> >$group is a newsgroup name; all queries go fine, except one that has
> >a dash in it. I have tried quoting $group, like:
> >
> >$newsgroup = $dbh -> quote ($group);
>
> That will work, unless you left the quotes around the variable in
> the statement.


I solved it. Stupidity was the cause. Mine, to be precise. :)

I had expired articles, and for one group there where no articles left
anymore thereafter. Had I taken the time to inspect my previous query, I
would have seen that min + max(article_num) were no longer defined,

"DBD::mysql::st execute failed: You have an error in your SQL syntax near '
stop= WHERE newsgroup = 'alt.support.abuse-partners'' at line 1 at
../MySQL-expire-news.pl line 34."

MySQL simply tripped over "stop" having no value anymore. I should have
realized that the placeholder I used to insert the entry, should also work
to select the entry, and that, hence, a different cause existed for the
failed query.

Sorry my frustration made me ask before I looked.

- Mark


---------------------------------------------------------------------
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