fixed bug: postgres djvison by zero error
various