added more function functionality to sum and added more tests to cover most of if not all of OQL