Using tcl, I'm reading through a file generated by a report-writer. There are some records that have tabs in them, some don't. I need to parse out the fields (columns in the report) positionally. The problem is using string range or crange views the \t in the records as single characters
I tried doing
regsub -all $rec \t " " rec
but since the amount of whitespace in a tab is not static, I was getting undesired results.
Example of report line:
10/27/08 801062347 801062347 .00 Charge 70.99 N
Corresponding example of octal display from the report file:
0001460 \r \n 1 0 / 2 7 / 0 8 \t \t
0001500 8 0 1 0 6 2 3 4 7 \t
0001520 8 0 1 0 6 2 3 4 7 \t \t .
0001540 0 0 C h a r g e \t \t
0001560 7 0 . 9 9 N \r \n
I'd prefer to handle this in the tcl script but if necessary, I suppose I can manipulate the file using ksh beforehand, although I'm not sure how I would do that either.
Any ideas?
20081119-EE-VQP-45 - Hierarchy / EE_QW_2_20070628