Closed Bug 325813 Opened 19 years ago Closed 18 years ago

running whine.pl spits out sql error when run

Categories

(Bugzilla :: Whining, defect)

x86
Linux
defect
Not set
normal

Tracking

()

RESOLVED DUPLICATE of bug 327348

People

(Reporter: jforman, Assigned: erik)

Details

Attachments

(1 file)

User-Agent:       Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7.12) Gecko/20060116 Firefox/1.0.7
Build Identifier: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7.12) Gecko/20060116 Firefox/1.0.7

I am trying to run "whine.pl" after enabling it for a subset of my users. I am trying to run whine.pl from the CLI first to test before I set a cronjob for it. I am receving this error. As suggested by Max, I am filing this bug with all pertinent information.

nuthatch htdocs # ./whine.pl
DBD::mysql::st execute failed: You have an error in your SQL syntax.
Check the manual that corresponds to your MySQL server version for the
right syntax to use near 'WHERE id = '1'' at line 1 [for Statement
"UPDATE whine_schedules SET run_next = CURRENT_DATE + INTERVAL ? DAY +
INTERVAL ? HOUR WHERE id = ?"] at ./whine.pl line 205


Reproducible: Always

Steps to Reproduce:
1. run "whine.pl"
2.
3.



Expected Results:  
Output nothing and sent out all requsted whine emails.

I am running bugzilla 2.20 on gentoo linux. The backend mysql server, on another machine as the httpd (apache) running bugzilla is version 4.0.24.
What's your version of DBD::Mysql? As said on IRC, this part of the code is executed when running a new whine for the first time. I cannot reproduce the problem.
*  dev-perl/DBD-mysql
      Latest version installed: 2.9007


I have the same problem here:

OS:    DEBIAN 3.0 (Woody)
MySQL: v3.23.49-log
DBI:   1.38

The error message is:

DBD::mysql::st execute failed: You have an error in your SQL syntax near 'WHERE id = '15'' at line 1 [for Statement "UPDATE whine_schedules SET run_next = CURRENT_DATE + INTERVAL ? DAY + INTERVAL ? HOUR WHERE id = ?"] at /var/www/sub-domains/info/bugzilla/whine.pl line 612
	main::reset_timer(15) called at /var/www/sub-domains/info/bugzilla/whine.pl line 296
	main::get_next_event() called at /var/www/sub-domains/info/bugzilla/whine.pl line 324
DBI::db=HASH(0x883fd24)->disconnect invalidates 1 active statement handle (either destroy statement handles or call finish on them before disconnecting) at Bugzilla.pm line 182.

I have fixed the problem in the whine.pl script (see patch).

Seems to be the same as bug 327348

*** This bug has been marked as a duplicate of 327348 ***
Status: UNCONFIRMED → RESOLVED
Closed: 18 years ago
Resolution: --- → DUPLICATE
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: