Data File Conversion
From Parse-O-Matic Wiki
The term "data file conversion", as used in the context of Parse-O-Matic, refers to parsing, analysis and output of one or more flat data files.
Consider this sample CSV (Comma Separated Value) file, which comprises two records of three fields each, listing name and address information.
"Smith","John","1234 Happy Lane" "Jones","Mary","5678 Dour Lane"
This file is not easily read by humans, so we might convert it to this:
John Smith lives at 1234 Happy Lane Mary Jones lives at 5678 Dour Lane
We could simply re-type the data, but for large files this would be impractical. Instead, we could process the input file with the following Parse-O-Matic script.
Fields = SplitCSV $Data '/' LastName = Parse Fields '' '/' 'Cut' FirstName = Parse Fields '' '/' 'Cut' Address = Fields OutEnd FirstName ' ' LastName ' lives at ' Address
This script takes apart each record of the input file, separating out the three fields into variables named LastName, FirstName and Address. It then rearranges these fields and sends them to the output file.
Parse-O-Matic data file conversion never changes the original input file. Rather, it reads an input file and creates a new output file according to the instructions in the script.
