added support for postgresql