• The Four Hundred
  • Subscribe
  • Media Kit
  • Contributors
  • About Us
  • Contact
Menu
  • The Four Hundred
  • Subscribe
  • Media Kit
  • Contributors
  • About Us
  • Contact
  • Kevin Juenemann’s Quick Query Utility

    October 4, 2006 Hey, Ted

    Note: The source code for this article is available for download

    Your QF command works great when you want to see the raw data, but sometimes you need only some of the columns, or need to join files to get usable data rather than codes. Many of our customers don’t have interactive SQL installed on their systems, so I created this utility and sent it to all our customers for those times a one-off report is needed quickly.

    I can enter an SQL Select statement and a printer ID, and the utility will create a Query Management Query and run it. One nice feature is that if the report is too wide for the paper, it will automatically create multiple reports that you can place side-by-side for a wide-view.

    –Kevin Juenemann, InfiniTec

    I greatly appreciate Kevin’s willingness to share his utility with readers of Four Hundred Guru.

    Kevin sent me three source members–a command, a CL program, and an RPG IV program. You can download the source code for each of these elements by clicking here. This file contains:

    • ptprtsel.cmd
    • ptprtsel.clp
    • ptprtselr1.rpgle

    I have included compilation instructions at the beginning of each member.

    Here’s an example of how I used PTPRTSEL in testing. The following command created a report and placed it on my output queue.

     PTPRTSEL SQL('SELECT STATE, CITY, LSTNAM, INIT, CUSNUM FROM qiws/qcustcdt
      ORDER BY STATE, CITY') PRINTER(THOLT)
    

    I hope many of you will find Kevin’s utility handy.

    –Ted

    RELATED STORY

    Quick Query Over a Database File

    Share this:

    • Reddit
    • Facebook
    • LinkedIn
    • Twitter
    • Email

    Tags:

    Sponsored by
    New Generation Software

    Do you work on IBM i? Do you need help explaining IBM’s strategy, navigating your company’s upgrade options, or learning about IBM i releases and TRFs? Would you benefit from current programming and application development tips and links to educational resources?

    NGS has created an IBM i resources page just for you. Don’t search the web and hope to find answers to your IBM i questions.

    Visit https://ngsi.news/ilinks

    We also encourage you to visit www.ngsi.com to learn about the latest release of NGS-IQ, our IBM i query, reporting, and analytics software.

    Share this:

    • Reddit
    • Facebook
    • LinkedIn
    • Twitter
    • Email

    Sponsored Links

    BCD:  Try WebSmart - the easiest and most complete iSeries Web development tool
    Profound Logic Software:  Experience RPGsp - the #1 iSeries Web development tool
    COMMON:  Join us at the Spring 2007 conference, April 29 – May 3, in Anaheim, California

    BOS CEO Steps Down, Company Brings in Outsider Replacement Details Emerge on Possible “Work Stream” Entry i5 Server

    Leave a Reply Cancel reply

Volume 6, Number 36 -- October 4, 2006
THIS ISSUE SPONSORED BY:

WorksRight Software
iTera
Patrick Townsend & Associates

Table of Contents

  • Kevin Juenemann’s Quick Query Utility
  • Remove Blank Lines from a Stream File
  • Admin Alert: Changing Physical File Characteristics on the Fly

Content archive

  • The Four Hundred
  • Four Hundred Stuff
  • Four Hundred Guru

Recent Posts

  • Stacking Up Power10 And Power11 Systems Price/Performance
  • Where Infor Is Headed With Its ERPs For IBM i
  • Rocket Delivers More DevOps Capabilities For IBM i
  • A Few More Power Systems Announcements Before Year End
  • IBM i PTF Guide, Volume 27, Number 46
  • Bang For The Buck On Entry Power10 And Power11 Machines
  • A Hardware Refresh Is The Perfect Time To Re-Evaluate Your HA/DR Strategy
  • Fresche Taps AI For New RPG-To-Java Conversion Tool
  • Gartner Raises 2025 IT Spending Forecast, Puts Out 2026 Prediction
  • IBM i PTF Guide, Volume 27, Number 45

Subscribe

To get news from IT Jungle sent to your inbox every week, subscribe to our newsletter.

Pages

  • About Us
  • Contact
  • Contributors
  • Four Hundred Monitor
  • IBM i PTF Guide
  • Media Kit
  • Subscribe

Search

Copyright © 2025 IT Jungle