Maybe this is required just in the case of a salted table? If that's the case, and there's no WHERE clause, this can be simplified.