Posgtres driver logic changed