import java.io.{BufferedReader, File, FileInputStream, InputStreamReader}
import org.apache.commons.csv.{CSVFormat, CSVParser, QuoteMode}
import scala.collection.JavaConverters._
object Test extends App {
val file = new File("xxx")
val br = new BufferedReader(new InputStreamReader(new FileInputStream(file)))
val csvFileFormat = CSVFormat.DEFAULT.withEscape('\\').withQuote('"')
val csvParser = new CSVParser(br, csvFileFormat)
val records = csvParser.getRecords
for (record <- records.asScala) {
val sb = new StringBuilder()
val length = record.size()
(0 until length).foreach(i => {