Opened 10 years ago

Closed 10 years ago

Last modified 10 years ago

#2810 closed defect (fixed)

fails when used with report containing LIKE operator

Reported by: anonymous Owned by: Shun-ichi Goto
Priority: normal Component: TicketBoxMacro
Severity: normal Keywords:
Cc: Trac Release: 0.10


Reports which contain something like the following work in the reports page, but fail with the TicketBox macro:

SELECT id AS ticket, summary FROM ticket

WHERE status IN ('new', 'assigned', 'reopened')

AND (owner='$USER' OR cc LIKE '%$USER%')

I guess that the problem is with the use of the % symbols in the LIKE string?

Attachments (0)

Change History (2)

comment:1 Changed 10 years ago by Shun-ichi Goto

Resolution: fixed
Status: newclosed

(In [3423]) Fix to use ReportModule.sql_sub_vars() for the issue #2810. Old code is not good for query like "... LIKE '%$USER%'" on 0.10.x or 0.11 on replacing variables. Close #2810.

And also drop supporting for trac 0.8 or before.

comment:2 Changed 10 years ago by Shun-ichi Goto

I'd reproduced your issue and fix it in r3423. Try it please.

Modify Ticket

Change Properties
Set your email in Preferences
as closed The owner will remain Shun-ichi Goto.
The resolution will be deleted.

Add Comment

E-mail address and name can be saved in the Preferences.

Note: See TracTickets for help on using tickets.