Add the stat procedure