Wednesday, September 15, 2021

New RPG BiF to retrieve greatest and lowest value in an array

%maxarray %minarray built in functions

The latest round of Technology Refreshes, IBM i 7.4 TR5 and 7.3 TR11, brought in three new additions to the RPG language. I thought I would start with two new Built in Functions, BiFs, that return the greatest or lowest value from an array.

The two new BiFs, %MAXARRAY and %MINARRAY, have the same syntax:

Wednesday, September 8, 2021

IBM Power 10 chips and server announced

power 10 e1080 announced

In what will be probably be the biggest announcement in the IBM i world this year IBM has announced their first server using the Power 10 chip, the E1080. I am not really a hardware guy, but I do appreciate the improved performance that the new Power 10 chip gives.

The ERP vendor SAP has developed their own SAP Application Performance Standard, SAPS, which they use to compare servers to one another. Their benchmark tests for the IBM Power 10 show that it outperforms Dell EMC PowerEdge with the Intel Xeon Platinum 8380 processor, SAPS 955.050 versus 248.530.

Even in a cloud environment 8 sockets, 160 cores of the IBM E1080 outperforms 16 sockets, 448 cores Google Cloud and HPE Superdome Flex.

Fall Technology Refreshes announced

ibm i 7.4 tr5 and 7.3 tr11

To accompany the announcement of the IBM Power 10 launch we also have the announcement of the Fall 2021 Technology Refreshes, TR, for the two supported releases of the IBM i operating system, 7.3 and 7.4 . These TRs are necessary if you want to move to the new Power 10 E1080 server.

Comparing the page for IBM i 7.3 TR11 and 7.4 TR5 they have the same additions and changes:

Tuesday, September 7, 2021

IBM Power 10 chip announcement tomorrow

ibm power 10 sneak peek

With the Power 10 announcement happening tomorrow I received a link to a sneak peek from IBM, which you can watch here.

Look for the "orbs" and click on them as they will reveal more information.

If you have not registered for the announcement tomorrow, Wednesday September 8, click on this link to do so.

Finding which display file field and record format the cursor is in

display field name retrieval

It has been a long time since I last wrote a post about display files, but I thought this was worth sharing. I was asked how you could determine which field the cursor is in when the prompt key is pressed. The prompt key is the SAA standard F4 key.

The person had found a very old program where the position of the cursor was returned as its location on the screen, as the row and column numbers. If this method was use they would have to determine the location of each field in the display file's record format.

I was asked is there an easier way?

Thursday, September 2, 2021

IBM Power announcement next week

Next week will be the biggest announcement from IBM this year, the next generation of IBM Power.

You can be there and learn about IBM Power 10 from the experts by attending this virtual announcement by signing up here.

Date:  Wednesday September 8, 2021
Time:  10:30 AM (US Eastern time)
Duration:  45 minutes

Wednesday, September 1, 2021

Getting information about the partition's disk drives using SQL

new columns added to sysdiskstat view and table function

Back in IBM i release 7.2 the SYSDISKSTAT SQL View was added. It was introduced to give similar information to what can be see using the Work with Disk Status command, WRKDSKSTS, and allow us to do more with that information. Over the next couple of releases there have been new columns added to it making it ever more useful. I have to admit I have been remiss not writing about it until now.

In the latest Technology Refreshes, IBM i 7.4 TR4 and 7.3 TR10, 37 new columns were added. There is also now a SYSDISKSTAT SQL Table Function, more about that later. In the examples I am going to give I am not going to use all 37 of the new columns, therefore, if you want to learn about them all click to the links to the IBM documentation at the bottom of this post.

With this statement I am going to get a snapshot of the which disks are the top five when it comes to the percent of the disk is used:

Wednesday, August 25, 2021

Changing user profiles using SQL

chgusrprf using sql

I have to admit when I read that a SQL table function to change user profiles had been introduced in the latest Technology Refreshes for IBM i 7.4 and 7.3 I was skeptical as to whether it was something that I would find practical and useful. Having had some time to play with it I can now appreciate its usefulness.

But before I get to that, let me explain how the CHANGE_USER_PROFILE table function works.

The table function will only change certain information of a user profile. The parameters you can change are:

Wednesday, August 18, 2021

CTE example: Calculating the maximum length of 80% of the rows in a column

common table express cte example

I don't have a good example of using a Common Table Expression, CTE, in this blog so I decided to write this one as an example of how I can determine the maximum length of 80% of the rows in a SQL Table.

It does sound a bizarre thing to calculate, but it was used in the post from last week where I discussed the fastest way to copy data from one file or table to another. IBM's recommendation was if you use a VARCHAR to define a column in a table using the ALLOCATE it could reduce the number of I/O operations that would be performed. The suggested allocation for any column is that the number of bytes allocated will include 80% of the rows in the table.

I decided to write the SQL statement I will show, below, to perform that calculation. I broke up what I wanted to do into "parts", this would allow me to test my results before going to the next "part".