Problem with CSVParser: can only iterate over an array or an instance of java.lang.iterable

25 views Asked by At

I have a problem with java. I'm basically using the CSVParser library to read CSV files. when I go to iterate a record it gives me the error. I'll post the code.

 Reader in = new FileReader(path);
        CSVParser parse = CSVFormat.DEFAULT.withHeader().withDelimiter(';').parse(in);
        
        
    for (CSVRecord record : parse) {
        

    }
0

There are 0 answers