added sum and count function, multiple value functions are now allowed