• The Four Hundred
  • Subscribe
  • Media Kit
  • Contributors
  • About Us
  • Contact
Menu
  • The Four Hundred
  • Subscribe
  • Media Kit
  • Contributors
  • About Us
  • Contact
  • Timestamps and V5R1 RPG

    August 28, 2002 Timothy Prickett Morgan

    Hey, Ted:

    I enjoy reading the tech tips in Midrange Guru, especially how to break up a string in Qshell . (You figured that out on a cocktail napkin at a bar, right?)

    Craig Rutledge’s recent tip on comparing timestamps in RPG free is a bit too “robust.” To create a timestamp, just do this:

    legacy_stamp = %date(legacy_date:*MDY) + %time(legacy_time:*hms);
    
    defined_stamp = defined_date + defined_time;
    

    — Chris

    I can’t take credit for the Qshell tip to split up a parameter. As with so many other RPG, CL, OCL, and VB tricks of the trade, I learned that tip from somebody else.

    Thanks for the simplified code. Craig and I had tried your method, but for some reason, we couldn’t get it to work.

    Several other readers sent in the same information. One of them, Carsten Flensburg, had the following comment to make:

    “Having a brief look in the manual didn’t reveal any documentation for this behavior, but I guess that’s a documentation issue rather than a compiler issue.”

    — Ted

    Sponsored By
    ADVANCED SYSTEMS CONCEPTS

    SEQUEL meets all your iSeries and AS/400 data access needs in a single, integrated solution:

    • Windows, Web or host user interfaces

    • Convert AS/400 data into PC file formats

    • E-mail or FTP query results, reports and spool files
    • Run-time prompted queries and reports for end users

    • IF-THEN-ELSE logic in queries and reports

    • Report, form and label formatting second to none

    • Easily convert date fields, character-to-numeric, numeric-to-character and other data manipulation

    • SORT or JOIN using a calculated field

    • Quick summarization of data with Tabling function

    • Run multiple SEQUEL requests as one with the SEQUEL Scripting function

    • OLAP Business Intelligence at a fraction of the cost of comparable solutions

    Take 6 minutes to view a SEQUEL ViewPoint ScreenCam movie to see how simple Windows-based AS/400 and iSeries data access can be! In just a few short minutes, you can find out ways to make your job easier and improve data access throughout your organization. Download the ViewPoint movie here .

    For more information or a FREE trial of SEQUEL, call 847/605-1311 or visit Advanced Systems Concepts.

    Share this:

    • Reddit
    • Facebook
    • LinkedIn
    • Twitter
    • Email

    Tags: Tags: mgo_rc, Volume 2, Number 65 -- August 28, 2002

    Sponsored by
    Racksquared

    It’s time for IBM Power in the Cloud!

    Stop buying hardware and make the move to the cloud. It’s easier and more cost effective than you might think.

    • IBM Power in the Cloud
    • IBM Power Backup Solutions
    • IBM Power High Availability and DR solutions
    • IBM Power Colocation with Management and Monitoring

    Let’s talk about your business needs.

    Call: 855-380-7225
    Email: Sales@racksquared.com

    Share this:

    • Reddit
    • Facebook
    • LinkedIn
    • Twitter
    • Email

    Odds and Ends Reader Feedback and Insights: Splitting a Qshell Variable

    Leave a Reply Cancel reply

MGO Volume: 2 Issue: 65

This Issue Sponsored By

    Table of Contents

    • Timestamps and V5R1 RPG
    • A CPYF Idiosyncrasy Revisited
    • Edit with Parentheses in Query/400

    Content archive

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

    Recent Posts

    • IBM Tweaks Some Power Systems Prices Down, Others Up
    • Disaster Recovery: From OS/400 V5R3 To IBM i 7.4 In 36 Hours
    • The Disconnect In Modernization Planning And Execution
    • Superior Support: One Of The Reasons You Pay The Power Systems Premium
    • IBM i PTF Guide, Volume 25, Number 13
    • IBM i Has a Future ‘If Kept Up To Date,’ IDC Says
    • When You Need Us, We Are Ready To Do Grunt Work
    • Generative AI: Coming to an ERP Near You
    • Four Hundred Monitor, March 22
    • IBM i PTF Guide, Volume 25, Number 12

    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 © 2023 IT Jungle