some mssql specific typechecking for aggregates and datepart

hack in quick partial support for typechecking datepart function
add new types for aggregates in mssql which differ from the types in
  postgres