summaryrefslogtreecommitdiffstats
path: root/sanitycheck.cgi
diff options
context:
space:
mode:
authorjustdave%syndicomm.com <>2003-03-08 17:29:01 +0100
committerjustdave%syndicomm.com <>2003-03-08 17:29:01 +0100
commitb5d2e0dd1d887e2db2976b98598f543417ab0507 (patch)
tree3e225423006aa477b295355263265b47b5db5e5c /sanitycheck.cgi
parentcd63e63ef7cac942ac11c4007d35725fd38ee9be (diff)
downloadbugzilla-b5d2e0dd1d887e2db2976b98598f543417ab0507.tar.gz
bugzilla-b5d2e0dd1d887e2db2976b98598f543417ab0507.tar.xz
Bug 196101: use ANSI-compliant SQL for group checks in sanitycheck
Diffstat (limited to 'sanitycheck.cgi')
-rwxr-xr-xsanitycheck.cgi26
1 files changed, 12 insertions, 14 deletions
diff --git a/sanitycheck.cgi b/sanitycheck.cgi
index f5b8be210..a28858f43 100755
--- a/sanitycheck.cgi
+++ b/sanitycheck.cgi
@@ -664,24 +664,22 @@ if ($c) {
}
Status("Checking for bugs with groups violating their product's group controls");
-BugCheck("bugs, groups, bug_group_map
- LEFT JOIN group_control_map
- ON group_control_map.product_id = bugs.product_id
- AND group_control_map.group_id = bug_group_map.group_id
- WHERE bugs.bug_id = bug_group_map.bug_id
- AND bug_group_map.group_id = groups.id
- AND groups.isactive != 0
+BugCheck("bugs
+ INNER JOIN bug_group_map ON bugs.bug_id = bug_group_map.bug_id
+ INNER JOIN groups ON bug_group_map.group_id = groups.id
+ LEFT JOIN group_control_map ON bugs.product_id = group_control_map.product_id
+ AND bug_group_map.group_id = group_control_map.group_id
+ WHERE groups.isactive != 0
AND ((group_control_map.membercontrol = " . CONTROLMAPNA . ")
OR (group_control_map.membercontrol IS NULL))",
"Have groups not permitted for their products");
-BugCheck("bugs, groups, group_control_map
- LEFT JOIN bug_group_map
- ON group_control_map.group_id = bug_group_map.group_id
- AND bugs.bug_id = bug_group_map.bug_id
- WHERE group_control_map.product_id = bugs.product_id
- AND bug_group_map.group_id = groups.id
- AND groups.isactive != 0
+BugCheck("bugs
+ INNER JOIN bug_group_map ON bugs.bug_id = bug_group_map.bug_id
+ INNER JOIN groups ON bug_group_map.group_id = groups.id
+ LEFT JOIN group_control_map ON bugs.product_id = group_control_map.product_id
+ AND bug_group_map.group_id = group_control_map.group_id
+ WHERE groups.isactive != 0
AND group_control_map.membercontrol = " . CONTROLMAPMANDATORY . "
AND bug_group_map.group_id IS NULL",
"Are missing groups required for their products");