![]() Tabular data handling toolkit |
fldmap(1) - map fields by name from one file to another
SYNOPSISfldmap [-H] sourcefile destfileDESCRIPTIONsourcefile and destfile are two tabular ascii files with field name headers. This utility will write the contents of sourcefile, reformatted to the field format of destfile, to stdout. This remapping is based on field names. Both files must have a field name header.
A warning will be issued for any field found in sourcefile that is not in
destfile, and such fields will not be present in the result. Destfile fields
not present in sourcefile will be filled in as nulls (the = character by
default but can be set to another symbol in
your config file
).
OPTION-H
EXAMPLESuppose file1 looks like this:id balance 001 4504 002 9403and file2 looks like this: id lastname firstname balance 101 Smith George 58300 103 Jones Jeff 4792If we issue the command: fldmap file1 file2 we will get the following on standard output: 001 = = 4504 002 = = 9403If we had used -H we would have gotten: id lastname firstname balance 001 = = 4504 002 = = 9403 |
![]() Tabular data handling toolkit Copyright Steve Grubb |