• The Four Hundred
  • Subscribe
  • Media Kit
  • Contributors
  • About Us
  • Contact
Menu
  • The Four Hundred
  • Subscribe
  • Media Kit
  • Contributors
  • About Us
  • Contact
  • Guru: A Bevy of BIFs – %Dec to the Rescue

    August 1, 2018 Susan Gantner

    Author’s Note: This tip was first published back in 2009. I’ve updated the code examples here to use free format declarations. In addition I’ve added the potential use of %ScanRpl, which didn’t exist at the original publication date.

    More and more in RPG applications these days, it seems we need to process data that comes from “the dark side.” Translation: from a non-i system. This data could be coming from a browser screen via an RPG CGI program, from a CSV (comma-separated values) flat file, from an XML or JSON document, or myriad other ways. One thing these dark sources …

    Read more
  • Guru: An Introduction to RPG’s XML-INTO, Part 1

    August 1, 2018 Jon Paris

    Author’s Note: The original version of this article was written in the V6 timeframe and included references to V5R4. References to the V5R4 limitations have been removed from this updated version. I have also updated the data definitions to take into account RPG’s ability for the direct coding of nested data structures rather than having to use LikeDS as before.

    RPG IV’s built-in XML support has been available for some time now, having been originally introduced with V5R4 back in 2006. However, it wasn’t until the advent of V6 with its removal of many of RPG’s size limits that it …

    Read more
  • Guru: RPG’s New DATA-INTO

    June 18, 2018 Jon Paris

    In this tip I’m going to give a brief introduction to the latest addition to the RPG language. The new DATA-INTO op-code. DATA-INTO is IBM’s response to the oft-asked question: “When is IBM going to introduce JSON-INTO so we can process JSON as easily as XML?”

    DATA-INTO provides this capability, but IBM has very cleverly given it functionality that goes way beyond what a simple JSON-INTO op-code could ever have done. DATA-INTO is effectively a cross between XML-INTO and Open Access. Like XML-INTO it uses the names of items and their hierarchy to unpack the document into RPG variables. Like …

    Read more
  • Guru: DB2 For i XML Composition And The IFS

    June 11, 2018 Michael Sansoterra

    Hey, Mike! Regarding Composing An XML Document From Relational Data, Part 1, I have built an XML document using DB2 and i. When I run the query, I get a worthless result set. How do I use the SQL XML functions to get a usable XML file?

    This question comes from reader RA, and he doesn’t exaggerate. The result set from his XML-based query looks like this:

    ....+....1....+....2....+....3....+....4....+
    ************Beginning of data************** 
    
    XMLDATA 
    -------- 
    #CGULIB#
    
      1 RECORD(S) SELECTED.
    
     ************End of Data********************
    

    Notice that DB2 for i does nothing to make the XML attractive to human eyes as the entire XML …

    Read more
  • Rest4i Eyes Digital Transformation Via API

    March 21, 2018 Alex Woodie

    A new company headed by IBM i software veterans is beginning to turn some heads with a new product aimed at helping IBM i shops with digital transformation strategies. Rest4i, as the outfit is called, says its LXR framework turns IBM i into a lean, mean REST API-serving machine.

    Stuart Milligan, who headed the UK software firm Databorough before it was sold to Fresche Legacy (now Fresche Solutions) way back in 2013, says LXR (pronounced “Lexer”) is the result of four years of investment and development in a “pure IBM i REST API solution.”

    Milligan describes LXR as …

    Read more
  • New IBM i Technology Refreshes Announced; Available Mid-March

    February 14, 2018 Dan Burger

    IBM yesterday announced that Technology Refresh 8 (TR8) for IBM i 7.2 and TR4 for IBM i 7.3 will provide support for Power9 hardware, enhancements for RPG, security enhancements, and a variety of new capabilities for licensed products. The support for Power9 will be covered elsewhere in this issue of The Four Hundred. Here, we’ll provide an overview of the IBM i operating system, licensed programs, and software.

    When TR enhancements include RPG, I like to begin there. Application developers using Rational Development Studio should take note of the new operation code referred to as DATA-INTO, which adds the …

    Read more
  • Guru: Consuming A REST Web Service Using SQL And GET

    September 18, 2017 Mike Larsen

    The use of web services in the industry continues to grow, and sometimes it can be challenging to find information on how to work with them on IBM i. So, what is a web service? In a nutshell, web services allow systems to communicate via the web using file formats such as JSON and XML.

    This article demonstrates how to consume a REST web service using SQL. The example I’m working with uses the ‘GET’ verb to retrieve information from an Amazon Web Service (AWS). I created a simple REST Amazon Web Service that retrieves information about a pet from …

    Read more
  • Does IBM i Need More Databases?

    August 14, 2017 Alex Woodie

    There are many things that differentiate IBM i from other platforms, including its storage, security, and programming models. But one of the most unique aspects of the IBM i platform is its integrated DB2 database, which is used exclusively by practically all IBM i customers. You just don’t find this on other platforms. But perhaps it’s time for IBM i to diversify its database support?

    In many respects, DB2 for i is the platform’s greatest strength. IBM i is renowned for its transaction processing prowess that drives ERP and other line of business applications, and DB2 for i (formerly DB2/400, …

    Read more
  • IBM i, Watson & Bluemix: The REST Of The Story

    June 21, 2017 Dan Burger

    Integrated Web Services is nothing new for IBM i. But that doesn’t mean there’s nothing new in Web services. A couple of years ago, IBM introduced Bluemix, an integration framework that, among other things, allows applications on other systems to connect with business logic running on i. The Bluemix tooling was designed to consume REST APIs, which can be used to connect Watson and IBM i. That’s where the newness is evident.

    The plumbing that’s necessary to make these things happen is being built by the IBM i development team led by Tim Rowe, business architect for IBM i …

    Read more
  • Guru: The XML Composition Conundrum of XMLNAMESPACES or XMLATTRIBUTES

    April 3, 2017 Michael Sansoterra

    Hey, Mike:

    After reading the IT Jungle Guru tips on DB2 XML Composition (see Related Stories below), I’ve been able to build XML from relational data. I have everything working but now I need to enclose all data in a “Document” tag after the XML declaration like the example here:

    <?xml version="1.0" encoding="utf-8"?>
    <Document xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
    xmlns="http://MyCompany.com" 
    xsi:schemaLocation="http://MyCompany.com validate.xsd">
    

    I tried using XMLNAMESPACES but can’t get it to produce the “xsi:schemaLocation” tag. How can I construct the document tag I need?

    –N.C.

     

    The problem here is that the xsi:schemaLocation in your example is not a namespace, but …

    Read more

Next Articles

Content archive

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

Recent Posts

  • MIMIX 11 Ships As Tech Outages Dominate Headlines
  • Could You Recover Tomorrow? A CISO’s Perspective On IBM i Security In 2027
  • Guru: RPG’s New %INFO BIF. Is It Time to Retire the SDS?
  • Big Blue Backs Off On Power Memory Redundancy As Memory Prices Soar
  • IBM i PTF Guide, Volume 28, Number 42
  • IBM i Delivers New Development Tooling With 2026 Fall Tech Refreshes
  • Big Blue Says AI Is Not Behind The Big Uptick In IBM i Security Alerts
  • Guru: Web Service With Pagination
  • The GenAI Revolution And Product Shortages Send IT Budgets Skyward
  • IBM i PTF Guide, Volume 28, Number 40

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