DB2 commands

Shared parsers for parsing output of the commands of IBM DB2

Db2ls - command db2ls -a -c

class insights.parsers.db2.Db2ls(context, extra_bad_lines=None)[source]

Bases: CommandParser, list

Parse the output of db2ls -a -c into a list of dictionaries.

Typical output of this command:

/opt/ibm/db2/V11.5: ::Fri Jan 14 20:20:07 2022 CST :0
/opt/ibm/db2/V11.5_01: ::Fri Feb 11 10:34:51 2022 CST :0


>>> type(db2ls)
<class 'insights.parsers.db2.Db2ls'>
>>> len(db2ls)
>>> db2ls[0]['PATH']
>>> db2ls[1]['PATH']
>>> db2ls[1]['VRMF']
>>> db2ls[1]['INSTALLERUID']

This method must be implemented by classes based on this class.