• The last line of the where clause reads:

    AND ((a.user_seeks + a.user_scans + a.user_lookups) = 0 OR a.user_updates = 0)

    I think "OR a.user_updates = 0" should be removed. For example, I've got an index with 9 million hits but no updates. This index is certainly not unused just because the data is static.