Bug 428173
Description
Jan Pazdziora
2008-01-09 19:25:32 UTC
Red Hat Bugzilla is now using version 3.2 of the Bugzilla codebase and therefore this bug will need to be re-verified against the new release. With the updated code this bug may no longer be relevant or may have been fixed in the new code. Updating bug version to 3.2. Bugzilla 3.2 no longer gives the database error but it does not produce the correct output either. Consider query https://bugzilla.redhat.com/buglist.cgi?query_format=advanced&product=Red+Hat+Network+Satellite&field0-0-0=flagtypes.name&type0-0-0=equals&value0-0-0=sat-5.2.0%2B which returns RHN Satellite bugs with sat-5.2.0+ set (102 bugzillas found today). Consider query https://bugzilla.redhat.com/buglist.cgi?query_format=advanced&product=Red+Hat+Network+Satellite&field0-0-0=flagtypes.name&type0-0-0=equals&value0-0-0=pm_ack%2B which returns RHN Satellite bugs with pm_ack+ set (1033 bugzillas found today). Now let's try to find bugzillas that have both flags set, for example 186920, 441342, or 441526: https://bugzilla.redhat.com/buglist.cgi?query_format=advanced&product=Red+Hat+Network+Satellite&field0-0-0=flagtypes.name&type0-0-0=equals&value0-0-0=sat-5.2.0%2B&field0-1-0=flagtypes.name&type0-1-0=equals&value0-1-0=pm_ack%2Bfield0-0-0=flagtypes.name&type0-0-0=equals&value0-0-0=pm_ack%2B The above produces Zarro Boogs found. Not the expected result. I've updated this bugzilla's summary. We may need to push this upstream or work in cooperation with them to find a solution to this problem. Red Hat Bugzilla is now using version 3.4 of the Bugzilla codebase and therefore this bug will need to be re-verified against the new release. With the updated code this bug may no longer be relevant or may have been fixed in the new code. Updating bug version to 3.4. Red Hat has now upgraded to Bugzilla 3.6 and this bug will now be reassigned to that version. It would be helpful to the Bugzilla Development Team if this bug is verified to still be an issue with the latest version. If it is no longer an issue, then feel free to close, otherwise please comment that it is still a problem and we will try to address the issue as soon as we can. Thanks Bugzilla Development Team I've verified that the issue is still present -- search https://bugzilla.redhat.com/buglist.cgi?type0-1-0=equals&field0-1-0=flagtypes.name&field0-0-0=flagtypes.name&query_format=advanced&value0-1-0=pm_ack%2B&type0-0-0=equals&value0-0-0=sat-5.2.0%2B&product=Red%20Hat%20Network%20Satellite still does not find any bugs. When comparing different values for the same Bugzilla field, there is a flaw in the SQL that is generated which causes an impossible comparison since the same column in a table cannot be equal to two different values. The workaround is to use a separate boolean chart when AND'ing two values from the same field. https://bugzilla.redhat.com/query.cgi?columnlist=bug_severity%2Cpriority%2Cop_sys%2Cassigned_to%2Cbug_status%2Cresolution%2Cshort_desc%2Cflags&field0-0-0=flagtypes.name&field1-0-0=flagtypes.name&product=Red%20Hat%20Network%20Satellite&query_format=advanced&type0-0-0=equals&type1-0-0=equals&value0-0-0=sat-5.2.0%2B&value1-0-0=pm_ack%2B FWIW, the backend Search.pm code is getting revamped for a future Bugzilla release but is a large undertaking. Dave Dave, the query from comment 7 works -- thanks! I think we can close this bugzilla now as the approach with two charts is sufficient. Perhaps it could at least detect when this combination of parameters is supplied and give a warning instead of pretending to carry out a query it can't actually handle correctly? I wonder if the fix is as simple as 'my $flags = "flags_$$chartid_$$row";' in _flagtypes_name() The 'cc' field suffers from the same bug if used within a chart. Version 4 also looks broken (but I've not tried it). It seems most of the queries using LEFT_JOIN fields forget to append a monotonic counter such as the row number when used within a chart. |