× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



Yes, we cleaned up db2util project that Tony Cairns started:
[1]https://github.com/IBM/ibmi-db2util
 
The output formats are pluggable, but currently there's no configuration
options for each format, but that could be added:
[2]https://github.com/IBM/ibmi-db2util/issues/8 (Contributions welcome).
 

----- Original message -----
From: Bryan Dietz <bdietz400@xxxxxxxxx>
Sent by: "OpenSource" <opensource-bounces@xxxxxxxxxxxxxxxxxx>
To: IBMi Open Source Roundtable <opensource@xxxxxxxxxxxxxxxxxx>
Cc:
Subject: [IBMiOSS] new db2util rpm
Date: Fri, Mar 8, 2019 10:48 AM
 
I noticed a new RPM out there :

db2util

looking at the help and trying out looks like it will be very useful.

I think it could use a column name option for CSV and SPACE formats.

Like the ability to use parms.

Bryan

db2util [options] <sql statement>
Options:
   -o <fmt>                   Output format. Value values for fmt:
                                json:
[{"name"}:{"value"},{"name"}:{"value"},...]
                                csv:   "value","value",...
                                space: "value" "value" ...
   -p <parm>                  Input parameter(s) (max 32)
   -h                         This help text
   -v                         Show version number and quit

Examples:
db2util "select * from QIWS.QCUSTCDT where LSTNAM='Jones' or
LSTNAM='Vine'"
db2util -p Jones -p Vine -o json "select * from QIWS.QCUSTCDT where
LSTNAM=? or LSTNAM=?"
db2util -p Jones -p Vine -o space "select * from QIWS.QCUSTCDT where
LSTNAM=? or LSTNAM=?"
--
This is the IBMi Open Source Roundtable (OpenSource) mailing list
To post a message email: OpenSource@xxxxxxxxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: [3]https://lists.midrange.com/mailman/listinfo/opensource
or email: OpenSource-request@xxxxxxxxxxxxxxxxxx
Before posting, please take a moment to review the archives
at [4]https://archive.midrange.com/opensource.

Help support midrange.com by shopping at amazon.com with our affiliate
link: [5]https://amazon.midrange.com
 

 

References

Visible links
1. https://github.com/IBM/ibmi-db2util
2. https://github.com/IBM/ibmi-db2util/issues/8
3. https://lists.midrange.com/mailman/listinfo/opensource
4. https://archive.midrange.com/opensource
5. https://amazon.midrange.com/

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.