[i] It was lucky that Harry had tea with Hagrid to look forward to, because the Potions lesson turned out to be the worst thing that had happened to him so far.
–– Harry Potter and the Sorcerer's Stone
[ii] a. Ed made the most mistakes of them all. b. It sold for the highest price ever paid for a Cezanne.
–– CGEL, p.1101
[ii] is called set comparison, for “one member is picked out as being at the top of the scale. In [ii] the set is identified by the NP them all: the comparison is between the members of this set with respect to how many mistakes they each made, with Ed ranked at the top of the scale. It is possible to omit the PP of them all, in which case the set being compared is identified contextually. In [iib] the comparison is between the prices paid for painting by Cezanne, and again one is picked out as being at the top of the scale - CGEL,1102”.
It seems like [i] is a kind of the set comparison, but I’m not sure for [i] has that-clause that could be understood as a relative one. Is the that-clause a set one or a relative?