"abc|xyz|".split("\\|").foreach(println) ===> only displaying abc and xyx
println("abc|xyz|".split("\\|").length) ===> length should be 3 but is showing as 2.
When I split a string with pipe delimited, and the value of the last column is empty. The split function is ignoring the last value.