No kidding. Could that have anything to do with splitting your input on ',' when there are no commas in the line at all? :slight_smile:

Your code is also very un-rubyish. A more idiomatic approach:

lines = File.new("data.csv").each_line { |line| lines << line.chomp!.split("^") } lines.each { |line| puts "First: #{line[0]}" }

FWIW,