Initial attempt at writing a pgSQL class.