def convert(data, _first)
      CSV.generate do |csv|
        data.each do |o|
          csv << o.values.map { |v| v == '' ? nil : v }
        end
      end
    end
def convert(data, _first)
      CSV.generate do |csv|
        data.each do |o|
          csv << o.values.map { |v| v == '' ? nil : v }
        end
      end
    end
Converts the given input data to the CSV format.

 @param [Array] data The data we wish to convert

 @param [Boolean] Is this the first output batch?

 @return [String] The converted input data in the CSV format