Parsing Examples

We thought that a few explicit examples would be good...The idea is to make our parsing extremely robust and flexible.

Delimiter Parsing

Our library is very flexible and lets you define both the delimiter character and the qualifier. The qualifier is character that may surround your element. Typically this would be a " in Excel, but Excel may not surround every element with it. Here are some examples:

DelimiterQualifierInputOutput
, " a,b,c 3 elements: "a" "b" "c"
, " "a,b,c" 1 element: "a,b,c"
, " "a,b","c" 2 elements: "a,b" "c"
, " a,b,c 3 elements: "a" "b" "c"
, " a",b,c" 1 element: a",b,c"
, " "test1",test2,"0.00","another, element here",lastone 5 elements: "test1" "test2" "0.00" "another, element here" "lastone"
, ' a,b,c 3 elements: "a" "b" "c"
, ' "a,b,c" 3 elements: ""a" "b" "c""
, ' "a,b","c" 2 elements: ""a,b"" ""c""
, ' a,b,c 3 elements: "a" "b" "c"
, ' a",b,c" 3 elements: "a"" "b" "c""
, ' "test1",test2,"0.00","another, element here",lastone 6 elements: ""test1"" "test2" ""0.00"" ""another" "element here\"" "lastone"

Fixed Width Parsing