• The Four Hundred
  • Subscribe
  • Media Kit
  • Contributors
  • About Us
  • Contact
Menu
  • The Four Hundred
  • Subscribe
  • Media Kit
  • Contributors
  • About Us
  • Contact
  • Copy a Subset of Records from One System to Another

    September 27, 2006 Ted Holt

    Recently, I needed an easy way to refresh a development system with a subset of records from a file on a production system. I needed a method that I could run unattended, during off hours. FTP, the Save-Restore commands, and the third-party file transfer utilities available to me are good tools, but they have their drawbacks. All of them require me to transfer complete files, even if I only want to transfer a subset of records. And it is difficult to determine whether FTP succeeds or fails in a batch job. I found an easy way to accomplish my

    …

    Read more
  • Stuffing Five Digits Into Four

    September 27, 2006 Ted Holt

    How do you stuff five digits into a four-digit database field? I found out recently that it can be done. Suppose you have a database file with a four-digit binary field.

    A          R REC                
    A            FIELD4         4B  
    

    If you use the Display File Field Description (DSPFFD) command to view the record layout of the file, you will find that FIELD4 occupies two bytes of storage. Two bytes can hold values from -32,768 to 32,767. (For more about why this is so, see When a 10-Digit Variable Won’t Hold a 10-Digit Number.

    If you use traditional I/O to try to

    …

    Read more
  • Admin Alert: Setting the Record Straight on iSeries Access and ODBC Freeware

    September 27, 2006 Joe Hertvik

    In a weekly column, important points can easily get muddied in the writing, which sometimes leads to incorrect information. This week, I am going to correct some previous mistakes I made while writing about IBM‘s iSeries Access for Windows product and about an ODBC freeware product. Mistakes can become opportunities when they help you question conventional wisdom, and a mistake can also highlight a better way of doing things.

    So please join me while I eat some crow washed down by a nice bottle of Chianti and some fava beans, as I tell you where I went wrong and

    …

    Read more
  • Redirecting a List of Qshell Commands

    September 20, 2006 Hey, Ted

    I need a little help with a Qshell script. I retrieve a list of IFS files that have a certain extension (a suffix precede by a period) and pipe the list into another process. Now I have to also include other files that have a completely different extension. I do not want to run the command twice, processing each type of file in turn. How do I redirect the output of more than one command into one output stream?

    –Brad

    OK, let’s set up the problem for the benefit of the readers. Suppose Brad’s script currently processes files with the

    …

    Read more
  • Include Comments in Query/400 Queries

    September 20, 2006 Hey, Ted

    OK, I’ll bite. In your article Query/400 Handles Zero Dates (Sort Of), from Four Hundred Guru Volume 6, Number 25, you said, “This is one way to include comments in a query.” Does that mean there are other ways I can include comments in queries?

    –Paul

    I know of one other way to comment result fields other than the one I used in that example. First, let’s review that method. Here’s the first result field in that article.

    Field       Expression                 Column Heading        Len   Dec
    SDNOT0      shipdt/(shipdt-0.0000001)  0=Ship date is zero     1     0
                                           1=ship date is not             
                                           zero                           
    

    In this

    …

    Read more
  • Admin Alert: Dissecting the Unusual QLGPGCMA.LOCALE Error

    September 20, 2006 Joe Hertvik

    One of my i5/OS partitions went haywire recently. Suddenly, some users couldn’t run Infor‘s SSA ERP LX package, an i5 Domino server wouldn’t reboot, and some users couldn’t sign on. These problems occurred because of an authority problem involving an i5 object named QLGPGCMA. This situation is commonly referenced on the Internet, but there isn’t much information about its cause. The good news is that once the problem is diagnosed, it’s fairly easy to cure.

    Diagnosing the Problem

    The QLGPGCMA.LOCALE problem is very simple. When it occurs, some of your once reliable applications and i5/OS features may simply stop

    …

    Read more
  • Developers Don’t Despair: Virtualize Your PC

    September 13, 2006 Michael Sansoterra

    Today’s developers often wear many hats: programmer, operator, help desk, and database administrator. Furthermore, they often support software on many operating systems (various versions of Windows, Linux, Unix, and so forth) with various versions of application software (Microsoft Office 97 or 2003, ERP clients, and so on) using a variety of developer tools (Visual Studio, Visual Studio .NET, Websphere Development Studio Client, Delphi, and others).

    It can be quite overwhelming for companies with small budgets to create testing and development environments for such a wide array of software. Fortunately, there is a way to deal with this type of

    …

    Read more
  • Unusual But Logical SQL Sorting

    September 13, 2006 Hey, Ted

    A physical file that I’ve loaded with data from another system has a department field that I would like to use for sorting. The department field contains a description, rather than a code. I need to sort the data on the description, but not in alphabetical order. That is, I want a certain department to appear first, then a certain department to appear next, and so on. The only way I know to pull this off is to create a little table that lists the departments and the order each one appears in the sort, but I do not like

    …

    Read more
  • Admin Alert: One Common Cure for SQL0901 Package Errors

    September 13, 2006 Joe Hertvik

    The SQL0901 error is an incredibly frustrating error that occurs with i5 ODBC, OLE DB, and JDBC connections. Because SQL0901 is a general SQL error, it can be difficult to diagnose and harder to solve. This week I will look at one specific SQL0901 scenario, where the failure occurs inside SQL’s extended dynamic package support, and I will show you how to deal with this error in an i5 environment.

    What is Extended Dynamic Package Support?

    While the SQL0901 error can refer to a broad range of issues, this article focuses on diagnosing and correcting problems associated with SQL extended

    …

    Read more
  • Undocumented Debugger Function

    August 30, 2006 Hey, Ted

    Here’s a tip for those readers who, like me, still have to use the full-screen, green-screen debugger. I accidentally discovered that RPG supports a debugging option that is not documented in either the help text or the RPG programmer’s guide.

    If you want to break a program or procedure when a variable has a certain value, you can use a conditional breakpoint. In the following example, the program breaks at statement 12 if variable STATE has the value TX.

    break 12 when state = 'TX'
    

    Suppose you want to stop when part of a field contains a certain value? The

    …

    Read more

Previous Articles Next Articles

Content archive

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

Recent Posts

  • Liam Allan Shares What’s Coming Next With Code For IBM i
  • From Stable To Scalable: Visual LANSA 16 Powers IBM i Growth – Launching July 8
  • VS Code Will Be The Heart Of The Modern IBM i Platform
  • The AS/400: A 37-Year-Old Dog That Loves To Learn New Tricks
  • IBM i PTF Guide, Volume 27, Number 25
  • Meet The Next Gen Of IBMers Helping To Build IBM i
  • Looks Like IBM Is Building A Linux-Like PASE For IBM i After All
  • Will Independent IBM i Clouds Survive PowerVS?
  • Now, IBM Is Jacking Up Hardware Maintenance Prices
  • IBM i PTF Guide, Volume 27, Number 24

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