I have a sql query returning the average and count of results matching column values. The issue is that $wpdb results works but only fetches the result for the first value i