mergetbl

Usage: mergetbl [options] < old_table column ... merge_table

This operator merges and/or deletes rows of 'old_table' based on data values in 'merge_table' in the specified column(s). Both tables should be sorted on the specified column(s).

In the normal case, one or more rows in 'merge_table' either replace one or more existing rows in 'old_table' if the key column(s) match, or are inserted in order if the key column(s) do NOT match.

If the delete option is specified on the command line, one or more existing rows in 'old_table' will be deleted if there is a key column(s) match and the data in the delete column is equal to the delete string, ">>DEL<<" (without the quotes) by default. The delete column is the first non-key column in 'merge_table'.

Both tables should have similar data structures. The header for the new rdbtable is taken from 'merge_table', thus allowing a change of header information to be made.

Options:

This operator writes an rdbtable via STDOUT. Options may be abbreviated.