move result smarts into the data managers for postgres and sqlserver