1Fsdb::Filter::dbcolmergUes(e3r)Contributed Perl DocumentFastdibo:n:Filter::dbcolmerge(3)
2
3
4

NAME

6       dbcolmerge - merge multiple columns into one
7

SYNOPSIS

9       dbcolmerge [-C ElementSeparator] [columns...]
10

DESCRIPTION

12       For each row, merge multiple columns down to a single column, joining
13       elements with ElementSeparator (defaults to a single underscore).
14

OPTIONS

16       -C S or --element-separator S
17           Specify the separator used to join columns.  (Defaults to a single
18           underscore.)
19
20       -e E or --empty E
21           give value E as the value for empty (null) records
22
23       This module also supports the standard fsdb options:
24
25       -d  Enable debugging output.
26
27       -i or --input InputSource
28           Read from InputSource, typically a file name, or "-" for standard
29           input, or (if in Perl) a IO::Handle, Fsdb::IO or Fsdb::BoundedQueue
30           objects.
31
32       -o or --output OutputDestination
33           Write to OutputDestination, typically a file name, or "-" for
34           standard output, or (if in Perl) a IO::Handle, Fsdb::IO or
35           Fsdb::BoundedQueue objects.
36
37       --autorun or --noautorun
38           By default, programs process automatically, but Fsdb::Filter
39           objects in Perl do not run until you invoke the run() method.  The
40           "--(no)autorun" option controls that behavior within Perl.
41
42       --header H
43           Use H as the full Fsdb header, rather than reading a header from
44           then input.
45
46       --help
47           Show help.
48
49       --man
50           Show full manual.
51

SAMPLE USAGE

53   Input:
54           #fsdb      first   last
55           John    Heidemann
56           Greg    Johnson
57           Root    -
58           # this is a simple database
59           #  | /home/johnh/BIN/DB/dbcol fullname
60           #  | dbcolrename fullname first_last
61           #  | /home/johnh/BIN/DB/dbcolsplit -C _ first_last
62           #  | /home/johnh/BIN/DB/dbcol first last
63
64   Command:
65           cat data.fsdb | dbcolmerge -C _ first last
66
67   Output:
68           #fsdb      first   last    first_last
69           John    Heidemann       John_Heidemann
70           Greg    Johnson Greg_Johnson
71           Root    -        Root_
72           # this is a simple database
73           #  | /home/johnh/BIN/DB/dbcol fullname
74           #  | dbcolrename fullname first_last
75           #  | /home/johnh/BIN/DB/dbcolsplit first_last
76           #  | /home/johnh/BIN/DB/dbcol first last
77           #  | /home/johnh/BIN/DB/dbcolmerge -C _ first last
78

SEE ALSO

80       Fsdb.  dbcolsplittocols.  dbcolsplittorows.  dbcolrename.
81

CLASS FUNCTIONS

83   new
84           $filter = new Fsdb::Filter::dbcolmerge(@arguments);
85
86       Create a new dbcolmerge object, taking command-line arguments.
87
88   set_defaults
89           $filter->set_defaults();
90
91       Internal: set up defaults.
92
93   parse_options
94           $filter->parse_options(@ARGV);
95
96       Internal: parse command-line arguments.
97
98   setup
99           $filter->setup();
100
101       Internal: setup, parse headers.
102
103   run
104           $filter->run();
105
106       Internal: run over each rows.
107
109       Copyright (C) 1991-2018 by John Heidemann <johnh@isi.edu>
110
111       This program is distributed under terms of the GNU general public
112       license, version 2.  See the file COPYING with the distribution for
113       details.
114
115
116
117perl v5.32.0                      2020-11-16       Fsdb::Filter::dbcolmerge(3)
Impressum