minor refactor for window function support
adding pg aggregate function support
add some test for pg aggregate support
add some tests for pg aggregate function support
fix a pg aggregate test defect