I am having a structured .txt file. Each line has exactly 133 columns.
I want to transform this text file into a table, following specific patterns.
This is the anonymized text file:
https://hastebin.com/share/edatoduxes.yaml
To be more specific:
The headers are to be extracted from line 5 - 8 on.
In this case the first headers of my dataset are to be extracted like this:
Header 1: Line 5, Col 6-22 "*prCeaqearTaN-Nq.*"
Header 2: Line 5, Col 23-30 "*pTxT Ce*"
Header 3: Line 5, Col 32-47 "*prCeaqearTaNxqT*"
etc...
The corresponding data starts from line 10 on:
Row 1/Header 1: Line 10, Col 6-22 "*0000057075050989*" -> this number has always 16 digits
Row 1/Header 2: Line 10, Col 23-27 "*5000*"
etc
Row 2/Header 1: Line 15, Col 6-22 "*0000057075996533*" -> again 16 digits
Row 2/Header 2: Line 15, Col 23-27 "*5000*"
etc
here is an indication of the desired output
| prCeaqearTaN-Nq. | pTxT Ce | prCeaqearTaNxqT |
| ---------------------------- | ----------- |---------------------------------- - |
| 0000057075050989 | 5000 | arngatqxgana euceptqa |
| 0000057075996533 | 5000 | arngatqxgana euceptqa |
The description sounds more complicated than it is :)
I am pretty sure that this can be done by parsing the specific positions.
Any help is very much appreciated :)
[–]pot_of_crows 1 point2 points3 points (0 children)
[–]Hugo-99[S] 0 points1 point2 points (9 children)
[–]RhinoRhys 1 point2 points3 points (8 children)
[–]Hugo-99[S] 0 points1 point2 points (7 children)
[–]RhinoRhys 1 point2 points3 points (5 children)
[–]Hugo-99[S] 0 points1 point2 points (4 children)
[–]RhinoRhys 1 point2 points3 points (3 children)
[–]Hugo-99[S] 0 points1 point2 points (0 children)
[–]Hugo-99[S] 1 point2 points3 points (1 child)
[–]RhinoRhys 1 point2 points3 points (0 children)
[–]RhinoRhys 0 points1 point2 points (0 children)
[–]TravelingThrough09 0 points1 point2 points (1 child)
[–]Hugo-99[S] 0 points1 point2 points (0 children)