DBROWENUMERATE(1)

πŸ“¦
version 3.9 Β· 3 versions
, in epel 9

πŸŽ€ NAME πŸŽ€

Okay so dbrowenumerate β€” straight from the User Contributed Perl Documentation crew β€” is here to enumerate rows, starting from zero. That’s it, that’s the job, and it slays at it πŸ’…

✨ SYNOPSIS ✨

dbrowenumerate

πŸ’– DESCRIPTION πŸ’–

Add a new column "count", incremented for each row of data, starting with zero. If you want control over the initial value or the increment, use dbrowaccumulate β€” this module is just a wrapper around that. No cap, it’s a tiny icon. 🫢

🌸 OPTIONS 🌸

  • -N or --new-name N β€” name the new column N. Defaults to "count".

This module also supports the standard jdb options:

  • -d β€” enable debugging output.
  • -i or --input InputSource β€” read from InputSource, typically a file name, or - for standard input, or (if in Perl) a IO::Handle, Fsdb::IO or Fsdb::BoundedQueue objects.
  • -o or --output OutputDestination β€” write to OutputDestination, typically a file name, or - for standard output, or (if in Perl) a IO::Handle, Fsdb::IO or Fsdb::BoundedQueue objects.
  • --autorun or --noautorun β€” by default, programs process automatically, but Fsdb::Filter objects in Perl do not run until you invoke the run() method. The "--(no)autorun" option controls that behavior within Perl.
  • --help β€” show help.
  • --man β€” show full manual.

πŸ¦‹ SAMPLE USAGE πŸ¦‹

Input:

#h account passwd uid gid fullname homedir shell
johnh * 2274 134 John_Heidemann /home/johnh /bin/bash
greg * 2275 134 Greg_Johnson /home/greg /bin/bash
root * 0 0 Root /root /bin/bash
# this is a simple database

Command:

cat DATA/passwd.jdb | dbrowenumerate

Output:

#h account passwd uid  gid fullname       homedir     shell     count
johnh      *      2274 134 John_Heidemann /home/johnh /bin/bash 0
greg       *      2275 134 Greg_Johnson   /home/greg  /bin/bash 1
root       *      0    0   Root           /root       /bin/bash 2
# this is a simple database
#  | /home/johnh/BIN/DB/dbrowenumerate

🌈 SEE ALSO 🌈

Fsdb, dbrowaccumulate.

πŸ‘‘ CLASS FUNCTIONS πŸ‘‘

The original page has this heading but no body text under it, so we’re keeping it adorably empty and not inventing anything. 🫢


This iconic page is from perl v5.32.1, dated 2024-08-02. Bye bestie, go enumerate those rows πŸ’–βœ¨

πŸ“¦ where this page comes from