Fix typos
Revise the SQLs
Rename rb_sum_strata to sum