Add support for median and rollup functions