Community Conundrum 28: News Engagement is live! Read More

Parsing fixed-width files

Level 1
Parsing fixed-width files
I am trying to parse a fixed-width format file, but I am getting an error when I try to enter values in the "column offsets" field. It allows me to save my settings without error, but it never generates a preview or schema. When I go back to the "Explore" tab, it gives the following error: "Failed to run". Followed by: "For input string: "2"". The number there is always the first value I put in the "column offsets" field.

I tried to included screenshots here, but the image embed button is not working for me (won't let me upload a file).
0 Kudos
2 Replies
Dataiker Alumni
Hi,

Here is an example value to put in the "column offsets" field:

0,3,4

Note that the first number should be 0, and that the last number must not be larger than the shortest input line. Is it adaptable to your case?
0 Kudos
Level 1
Author
That seems to have addressed the error. I think the problem was I had spaces in between the commas and numbers (e.g. "0, 3, 4" vs. "0,3,4").

Thanks!
0 Kudos
Labels (2)
A banner prompting to get Dataiku DSS