Closed
Bug 554986
Opened 15 years ago
Closed 15 years ago
Searching Quicksearch using the minus sign operator doesn't work
Categories
(Bugzilla :: Query/Bug List, defect)
Tracking
()
RESOLVED
FIXED
Bugzilla 3.6
People
(Reporter: mkanat, Assigned: mkanat)
Details
(Keywords: regression)
Attachments
(1 file, 1 obsolete file)
5.27 KB,
patch
|
LpSolit
:
review+
|
Details | Diff | Splinter Review |
As of 3.6, you can't search for -6 in Quicksearch, it throws: Specified comparison type not supported.
Flags: blocking3.6+
Assignee | ||
Updated•15 years ago
|
Target Milestone: --- → Bugzilla 3.6
Assignee | ||
Comment 1•15 years ago
|
||
Okay, this is because there's no negation for "matches". (There's no notmatches.) Also, you can't just search for "'-6' IN BOOLEAN MODE" using the MySQL fulltext engine--it returns 0 results (this is documented). So we have to add a notmatches type.
Assignee | ||
Comment 2•15 years ago
|
||
Okay, this adds a "notmatches" search type, so that using negation on bare words in Quicksearch will work. In order for "Edit Search" to work, I also had to add it to the query page.
Assignee: query-and-buglist → mkanat
Status: NEW → ASSIGNED
Attachment #434918 -
Flags: review?(LpSolit)
Updated•15 years ago
|
Keywords: regression
Updated•15 years ago
|
Attachment #434918 -
Flags: review?(LpSolit) → review-
Comment 3•15 years ago
|
||
Comment on attachment 434918 [details] [diff] [review]
v1
With your patch applied, the boolean chart "commenter matches foo" crashes with:
Can't use string ("") as a subroutine ref while "strict refs" in use at Bugzilla/Search.pm line 1516.
at Bugzilla/Search.pm line 1516
Bugzilla::Search::_commenter('Bugzilla::Search=HASH(0xa689740)', 'sequence', 'SCALAR(0xa2baea8)', 'ff', 'SCALAR(0xa2baef8)', 'wherepart', 'ARRAY(0xa2a5b50)', 'supptables', 'ARRAY(0xa2a5b30)', ...) called at Bugzilla/Search.pm line 844
Bugzilla::Search::init('Bugzilla::Search=HASH(0xa689740)') called at Bugzilla/Search.pm line 198
Bugzilla::Search::new('Bugzilla::Search', 'fields', 'ARRAY(0xa399b20)', 'params', 'Bugzilla::CGI=HASH(0xa4e6408)', 'order', 'ARRAY(0xa3ae680)') called at /var/www/html/bugzilla/buglist.cgi line 829
instead of throwing:
The "content" field can only be used with "matches" search and the "matches" search can only be used with the "content" field.
as it does without your patch.
Otherwise looks good and seems to work correctly.
Assignee | ||
Updated•15 years ago
|
Attachment #434918 -
Flags: review- → review?(LpSolit)
Assignee | ||
Comment 4•15 years ago
|
||
Comment on attachment 434918 [details] [diff] [review]
v1
(In reply to comment #3)
> Can't use string ("") as a subroutine ref while "strict refs" in use at
> Bugzilla/Search.pm line 1516.
Okay, I just checked, and on trunk (but not on 3.6), this is happening without my patch. So it would be a separate bug.
Comment 5•15 years ago
|
||
(In reply to comment #4)
> Okay, I just checked, and on trunk (but not on 3.6), this is happening
> without my patch. So it would be a separate bug.
I tested with 3.7, and the crash doesn't happen without your patch.
Assignee | ||
Comment 6•15 years ago
|
||
Comment 7•15 years ago
|
||
(In reply to comment #6)
That's not the query I'm talking about. I'm talking about:
https://landfill.bugzilla.org/bugzilla-tip/buglist.cgi?field0-0-0=assigned_to&type0-0-0=matches&value0-0-0=sasdf
notmatches is a URL hack, while this one is a perfectly valid one, which you can get from the UI.
Assignee | ||
Comment 8•15 years ago
|
||
Oh, okay. Will look into it. Still, from the code I can see in Search.pm, the bug *should* already be happening. Not quite sure what's up.
Assignee | ||
Comment 9•15 years ago
|
||
This fixes it.
Attachment #434918 -
Attachment is obsolete: true
Attachment #435499 -
Flags: review?(LpSolit)
Attachment #434918 -
Flags: review?(LpSolit)
Comment 10•15 years ago
|
||
Comment on attachment 435499 [details] [diff] [review]
v2
Seems to work fine, now. r=LpSolit
Attachment #435499 -
Flags: review?(LpSolit) → review+
Updated•15 years ago
|
Flags: approval3.6+
Flags: approval+
Assignee | ||
Comment 11•15 years ago
|
||
Committing to: bzr+ssh://bzr.mozilla.org/bugzilla/trunk/
modified Bugzilla/Search.pm
modified Bugzilla/Search/Quicksearch.pm
modified template/en/default/global/code-error.html.tmpl
modified template/en/default/global/field-descs.none.tmpl
modified template/en/default/list/list.html.tmpl
modified template/en/default/search/boolean-charts.html.tmpl
Committed revision 7100.
Committing to: bzr+ssh://bzr.mozilla.org/bugzilla/3.6/
modified Bugzilla/Search.pm
modified Bugzilla/Search/Quicksearch.pm
modified template/en/default/global/code-error.html.tmpl
modified template/en/default/global/field-descs.none.tmpl
modified template/en/default/list/list.html.tmpl
modified template/en/default/search/boolean-charts.html.tmpl
Committed revision 7059.
Status: ASSIGNED → RESOLVED
Closed: 15 years ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•