From: Greg Sabino Mullane Date: Thu, 6 Oct 2011 16:39:26 +0000 (-0400) Subject: Show bloat when indexes are high too X-Git-Tag: 2.19.0~38 X-Git-Url: http://git.postgresql.org/gitweb/?a=commitdiff_plain;h=674fefa997d4ef8dfe1b064034fdf3d5b6961d45;p=check_postgres.git Show bloat when indexes are high too --- diff --git a/check_postgres.pl b/check_postgres.pl index 2fad37a99..ccf62a072 100755 --- a/check_postgres.pl +++ b/check_postgres.pl @@ -3467,7 +3467,7 @@ FROM ( if (! defined $opt{include} and ! defined $opt{exclude}) { $SQL .= " WHERE sml.relpages - otta > $MINPAGES OR ipages - iotta > $MINIPAGES"; - $SQL .= " ORDER BY wastedbytes DESC LIMIT $LIMIT"; + $SQL .= " ORDER BY (wastedbytes + wastedibytes) DESC LIMIT $LIMIT"; } else { $SQL .= ' ORDER BY wastedbytes DESC';