Finishing off 'query2*' scripts

Database/hosts_list.tpl, Database/hosts_showcount.sqlite.sql: examples
    of using 'query2tt2'

Database/query2csv, Database/query2json, Database/query2tt2: minor bug
    fix relating to '-dbarg=ARG' option
This commit is contained in:
Dave Morriss
2025-05-09 14:15:41 +01:00
parent bf8f6db45c
commit fdd0823f93
5 changed files with 65 additions and 12 deletions

View File

@@ -21,7 +21,7 @@
# AUTHOR: Dave Morriss (djm), Dave.Morriss@gmail.com
# VERSION: 0.0.4
# CREATED: 2015-07-11 15:53:01
# REVISION: 2025-05-07 17:20:00
# REVISION: 2025-05-09 14:13:17
#
#===============================================================================
@@ -359,8 +359,8 @@ sub _dbargs {
my @args;
if ( defined( $opts->{dbargs} ) ) {
@args = @{ $opts->{dbargs} };
if ( defined( $opts->{dbarg} ) ) {
@args = @{ $opts->{dbarg} };
}
return (@args);
@@ -381,7 +381,7 @@ sub Options {
my @options = (
"help", "documentation|man", "debug=i", "config=s",
"output=s", "query=s", "dbargs=s@", "header!",
"output=s", "query=s", "dbarg=s@", "header!",
);
if ( !GetOptions( $optref, @options ) ) {