September 11, 2014

We just finished delivering the second part of an introductory RPG class to the group of Java programmers that we mentioned in our "Programming Highs and Tire Lows" blog entry back in July. To say that we're brain dead is to put it mildly! Teaching these young, enthusiastic programmers really kept us on our toes, but it was a joy nonetheless. Hopefully we'll be doing a lot more of this kind of training in the future.

New iPhones and More

We admit to being Mac junkies but, although we both also use iPhones, we weren't exactly on the edge of our seats waiting for this week's announcements because we don't have any plans to replace our phones any time soon. We both also use FitBits, so even the much rumored iWatch, or as we now know it to be the Apple Watch, didn't hold as much interest for us as it otherwise might.

So in a way we were expecting this announcement to be somewhat anti-climatic. After all, anticipation has been building for so long that even Apple was going to be hard pressed to meet expectations. And yet it did. And we can't help but feel that in many ways it exceeded them. Both of the new iPhone models raise the game yet again in almost every category from form factor to appearance to speed to battery life to. ... And the Apple Watch--wow, that is one beautiful looking piece of technology. Pity we have to wait until 2015 to get our hands on one or that might have taken care of our Christmas shopping FitBit or no. Well, probably not. We learned a long time ago that being first in line for any new technology is risky and we usually wait a while, but darn it, that Dick Tracey watch phone notion is mighty tempting.

We know before we even finish this that the Apple haters and Android fan boys will be all over this piece. So be it. Apple rarely disappoints and we were very impressed by what we saw this week.

Whether the Apple Watch can define a whole new market in the way the iPhone and iPad did remains to be seen, but they sure look great!

September 02, 2014

As part of our preparations for the upcoming RPG & DB2 Summit in Minneapolis we've just released the latest edition of our "Favorite Keyboard Shortcuts for RSE" card. All you RSE/RDi users out there, feel free to download and print it. Alternatively there's an email link on the page where you can ask for hard copies of the shortcut card, which are a bit more durable and easier to pin up next to your workstation.

If you already have an earlier version of the card, you won't notice a dramatic difference, but we have made several improvements. For example, this one has a new section for the debugger shortcut keys, which were missing from the earlier versions of the card. Plus a few editor shortcuts have been added for commenting or uncommenting statements in RPG and switching between sides of a single-member split view, among others.

It was a bit of challenge finding space for the new stuff we wanted to add as the list has grown quite a bit from our original version (this is about the 4th edition). We toyed with the idea of making the fonts smaller, but decided that if we did that, our old eyes probably wouldn't be able to read them any more. We're sure the younger RSE users out there wouldn't have any trouble, but we would like to be able to use the card too! Instead, we gained some space by condensing a few of the items in the "Windows Shortcuts" section, taking multiple lines down to a single line. We figure that many RPGers are now more comfortable with Windows applications than when we first created this card and so don't need quite as much help with those.

There's also a new "tip" on the back--a very brief tutorial on getting started with Service Entry Point (aka SEP) debugging for those who may still be struggling with making the integrated debugger work.

Of course, no sooner had the email about the new card gone out to the folks on our System i Developer mailing list than an email came in suggesting that we missed a good shortcut--Ctrl-Shift-D for filtering a source member by change date! Thanks for that tip, Irene. We agree it is a good candidate to add to the list. If only we had thought to ask folks for suggestions _before_ we printed 1,000 copies of the card <sigh>.

Then again, it's never too early to start planning for the next version! So everyone else--please send in your own ideas of shortcuts that we missed. It will probably be a while before we reprint the cards again (unless it becomes so popular that the 1,000 copies we have get used up quickly!)

In the meantime, if we get lots of good suggestions, we'll start an addendum to the card online in the form of an extra item on our "RSE Tips" page.

So please tell us about your own favorite shortcut keys in the comments section. We're sure there are some great ones that we simply haven't bumped into yet and you can never have too many shortcuts!

August 26, 2014

In a recent post, we voiced our concerns about the potential for application error when taking advantage of the masking support related to RCAC in V7.2 of DB2 for i.

One of our concerns was about the potential loss of data when updating a row (aka record) that contained a masked column (aka field) value. For example, a credit card number might be masked like XXXX-XXX-XXX-1057 when retrieved in an RPG program. When that row is updated by the program, it’s quite possible that the actual value of the credit card number might be lost (i.e., overwritten by the masked value as seen by the RPG program).

Our friend, Kent Milligan, commented on the blog that there was support added to DB2 for i to allow the database itself to prevent data loss in that situation. Since we don’t yet have a 7.2 system to “play with” ourselves, we haven’t been able to pursue that and/or other potential solutions for that particular issue. We did, however, recently see an article Kent wrote on the subject.

The basic idea is that DB2 for i has implemented an enhanced capability for check constraints. Typically, if an “ordinary” check constraint were in place, an update to the row would be prevented if the check constraint were violated. That basic support could be used to prevent accidental loss of data by preventing updates if, for example, the first 12 characters of the credit card number were ‘XXXX-XXX-XXX’ (i.e., the mask value). But the problem is that we wouldn’t be able to update any other values in the row either if we had a masked credit card value in our program.

So the new support has added syntax on the check constraint “On Update Violation Preserve <column-name>.” This enhanced support means that if DB2 detects the specified value (i.e., the mask value), then updates will be allowed for other columns in the row but the original unmasked value for the credit card number will be retained. Whew!

Note that it will be necessary to set up this new check constraint option in addition to setting up the RCAC support to mask the column value. Also it doesn’t actually detect that it’s a mask put in by DB2; it only checks for a specific value. So potentially there could be other uses for this support beyond dealing with the RCAC-masked columns—although we can’t think of any.

We encourage you to learn more about this from Kent’s article. This new support doesn’t do away with all our concerns about masked values but at least, if implemented correctly, it would appear to avoid the worst of the potential nightmare scenarios! It may not be the solution we’d have preferred but it should help to prevent many of the mistakes we feared.

August 19, 2014

Back in March 2013 we wrote an article for the IBM i Extra enewsletter in which we covered the basics of the new iSphere plug-in for RDi. Since that time, iSphere has received several enhancements, so when we saw the announcement this week of an updated version, we decided we had to take another look. Boy are we glad we did! The range of features they have added to this excellent tool is impressive.

We intend to do a complete report, which we will be publishing in an upcoming edition of the IBM i Extra enewsletter, but we wanted to give our fellow RDi enthusiasts a heads-up in advance because some features are so good you should be using them today.

The latest version includes the following features:

Message File Searching and Editing

Binding Directory Editor

Compare/Merge Editor

Fast search feature for source files.

Ability to open spooled files in Text, HTML or PDF format.

Task Tags

Decorators for objects in the RSE tree view

The search capabilities alone are worth the price of admission. They are blazingly fast. Quite how they have managed to so significantly outperform IBM's own source search capabilities we don't know, but they have--by an order of magnitude. The developers claim up to 60 times faster than IBM's version and based on our limited experience we would not argue with that claim.

Task tags are a nice extension to the standard task support. Simply add a simple comment to your source file to remind you to perform a specific task (e.g., "// TODO must add prototype definitions") and when you save the source a new task is added to the task list. Later, when you find the time to catch up on some of your outstanding tasks, simply clicking on a specific item opens the source file and positions to the task marker. Later, when you have completed your work, simply delete the comment (or just remove the characters "TODO" from the text), save the file and the outstanding task list is automagically updated.

Last, but not least, the new Decorator support. When enabled (via Preferences) the file/member/object description is displayed alongside the object's name. Makes it so much easier to see which source member (for example) it is that you need to open.

You can download the latest version of the plug-in from iSphere's SourceForge page. Documentation is a little thin on the ground right now although some has been incorporated in RDi's help system. The only "official" install instructions we can find are in the project's wiki. The installation is covered here. Don't skip the final step, it installs the server components which are essential to the plug-in function.

We really think you'll enjoy using this new tool. Our congratulations to the development team; it really appears to be a great productivity booster.

IBM Systems Magazine is a trademark of International Business Machines Corporation. The editorial content of IBM Systems Magazine is placed on this website by MSP TechMedia under license from International Business Machines Corporation.