Thursday, February 23, 2017

PTF cover letters for 7.3 TR2 and 7.2 TR6

ptf cover letter for ibmi 7.3 tr2 7.2 tr6

The cover letters for the PTFs for IBM i 7.3 TR2 and 7.2 TR6 were released onto IBM's Support site yesterday. You can find them at:

The PTFs will be available for download on March 17, 2017.

For the details about what will be in these Technical Refreshes see IBM i 7.3 TR2 and 7.2 TR6 announced, which gives you an overview and has links to all the information from IBM.

Wednesday, February 22, 2017

Why I should be using the QCMDEXC SQL procedure

using sql procedure qcmdexc rather than api

My favorite API has to be QCMDEXC. I think it was the first API I used when I when I was making the transition from RPGII to RPGIII many, many years ago. I use it so often I think half the programs I write have it in them. QCMDEXC allows me to execute any CL command that does not return any values.

For several releases there has been a SQL procedure QCMDEXC, which does the same as the API. Then in IBM i 7.1 TR7 there was an update to the SQL procedure. You will find that I have used it in several examples in prior posts, but I have not given it its own post until now. I have to confess that I am so accustomed to using the API program version of QCMDEXC, I keep forgetting to use the SQL procedure.

Wednesday, February 15, 2017

Using API to test Help Panels

quhdsph api to diplay uim help module text

After publishing the post about how to create help text for display files using UIM several people messaged me that there is an IBM i API that can be used to test the help, without needing to add code to a display file. I have to admit I was unaware of the API, and am grateful to those who messaged me.

I decided to create a program to call the Display Help, QUHDSPH, API that way I can have a simple user interface to use, I only need to enter the variables I want and leave the rest with there defaults. I am going to show a very simple example here to illustrate how QUHDSPH can be used. As this is a simple example program a lot of the code I would add for myself, for validation etc. is not present.

For simplicity I am using a display file to enter the variables for the help module I want to see. There are other ways I could have done this, perhaps using a command instead, but I want this to be K.I.S.S compliant.

Tuesday, February 14, 2017

IBM i 7.3 TR2 and 7.2 TR6 announced

ibmi 7.3 tr2 and 7.2 tr6

Steve Will, chief architect of IBM i, made the "spring" announcement of new Technical Refreshes for 7.3 and 7.2 in his You and i blog earlier today.

Included in the announcement:

  • A new lower end PowerSystems server, S812.
  • DB2 (SQL) enhancements
    • New

Monday, February 13, 2017

Video: 7.3 TR1 and 7.2 TR3 latest and greatest

A video by IBM's Tim Rowe going into many of the cool things that came out with IBM i 7.3 TR1 and 7.2 TR3, that was released last October.

Wednesday, February 8, 2017

Adding UIM help to the Display file

add code to dds for help to be displayed

Having created a UIM help panel group I need to add the code to my Display file's DDS so that the help will be displayed. This post is going to use the UIM panel group that was created in my previous post to demonstrate, in simple terms, how to do this. I have designed a very simple display file to only include what I think is the minimum needed for it to work.

Most people have no idea where to find the Help key in their 5250 emulation client, therefore, as per SAA CUA standards I always define F1 as an alternate help key. I define the alternate help key in the file level keywords, top before the first record format definition, of the display file.

Rather than use SDA I find it easier to enter this source code using a source code editor, for example SEU. Therefore, I will be describing how to add this code as if I am using a source code editor.

Wednesday, February 1, 2017

Creating help text using UIM

uim panel group help

Thanks to UIM, User Interface Manager, designing help for your DDS display files is very simple. UIM has been used by IBM for their screens, menus, and help panels since the launch of the AS400, it was not until V2R1, 1991, that it was made available to programmers to create their own help panels. The "language" itself is easy to become familiar with and its compile listings are some of the easiest to decipher on IBM i.

In this post I am going to show how to create UIM help panels that can be used in DDS display files, and in a second post how to add the various DDS keywords to your Display file source code to use the UIM help panels.

Monday, January 30, 2017

Steve Will: What is coming in 2017

This is a short video that Steve Will, IBM i's chief architect, made for OCEAN user group of Southern California about what is coming in 2017.

This compliments his earlier blog post about the future of IBM i.

Wednesday, January 25, 2017

Recovering source for a Physical file

recover source for physical file

I am sure this has happened to us all: I have an object and the source it was compiled from is missing. In an earlier posts I showed how I could retrieve the source code from a program, but what about other object types?

Many, many years ago I wrote a command and programs to retrieve the source code for various types of files. When I recently found a physical file with its source missing I thought "I will just use my retrieve command". To my horror I found the command source and object in my personal tools library, but the programs and their source were missing. I may only use this command once in a very long time, but in the past it had proved invaluable in recovering the source for physical, display and printer files. I decided to go ahead and recreate the programs, in several stages. First I want to be able to recover the source for a physical file, then I would move onto the more complicated arrangements found within display and printer files. This post will describe the first stage of this journey, recovering the source for a physical file. The later stages will be covered in future posts.

Monday, January 23, 2017

Steve Will: IBM i future 2017 update

 

The web page that was originally linked to no longer exists, therefore, rendering this page obsolete.

 

Wednesday, January 18, 2017

Easy way to merge data using SQL

merge statement in sql

I had a project where the first step was to merge data from three files into one. I have used the word "merge" deliberately to differentiate it from "copy". With a "merge" I needed to update specific fields if a record is present in the output file with a matching key. If there is no matching key record I add a new record. I have done this many times in RPG, this time I wanted to try something different, like SQL.

After searching IBM's KnowledgeCenter I discovered the MERGE SQL statement. I do not know when it was released, but searching in the different versions of the KnowledgeCenter I can find it in the versions for IBM i 7.1, 7.2, and 7.3, but I cannot find it in the earlier releases. The MERGE does exactly what I want it to, it will update on a match and insert when there is no match.

Wednesday, January 11, 2017

Using auditing columns to audit data

generated audit columns

The germ for this post came from a comment made by a work colleague. I always insist that all master files have a "Last update user” and "Last update timestamp" field, making it possible to know when a particular record was last changed and who did it. "Wouldn't it be nice if the system updated the audit user and time for us," my colleague said looking at an old master file without these fields. This sent me to IBM's KnowledgeCenter to see if this was possible, and after a while of poking around I found the way to do it, auditing columns.

If a file or table has auditing columns, every time data is added to or changed the auditing columns will be automatically updated by the IBM i database manager, no extra coding needed in my RPG or SQL. I cannot move values to these columns, thereby, ensuring that the information contained within is sacrosanct. I cannot define auditing columns in DDS, if I need to add them to DDS file I would use the SQL ALTER TABLE statement. There are 21 types auditing columns covering all kinds of information, but in my scenario I just want to add auditing columns that will allow me to see: