Support for postgresql

I think it was the last request using 'end' missing the postgresql support.