 <p>In MapReduce, have the first line of your mapper parse the line it is reading. You can do this with custom parsing logic, or you can leverage pre-built code (in this case, a CSV library).</p> <pre><code>protected void map(LongWritable key, Text value, Context context) throws IOException { String line = value.toString(); CSVParser parser = new au.com.bytecode.opencsv.CSVParser.CSVParser(); try { parser.parseLine(line); // do your other stuff } catch (Exception e) { // the line was not comma delimited, do nothing } } </code></pre>