0

How i load a csv separate by ";" now I'm using this function by don't works correctly.

val accidentesDF=sqlContext.read.format("csv")
        .option("header", "true")
          .load("src/main/resources/TABLA_ACCVICT_2013.csv");
1
  • You should add the delimiter option in the chain: .option("delimiter", ";") Commented May 4, 2016 at 22:57

1 Answer 1

1

Try

val accidentesDF=sqlContext.read.format("csv")
        .option("header", "true")
          .load("src/main/resources/TABLA_ACCVICT_2013.csv", Map("delimiter"->";"));
Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.