Instead of exporting ratings directly from query, why not build the functionality to export ratings by date similar to how we can export solicitors based on date to/date from ascending/descending? It would be much easier than having to merge this data into an export afterwards and certainly cleaner than exporting from query.