fix for empty resultset