Added support for Having clause on Select statements

I notice there was already a Having class in the code, but it doesn't appear to be used anywhere. I believe this commit adds proper support for using the having clause, but this might need some looking over.