Revert postgresql changes pending further testing and fixes; this breaks currently...