Register a SA Forums Account here!
JOINING THE SA FORUMS WILL REMOVE THIS BIG AD, THE ANNOYING UNDERLINED ADS, AND STUPID INTERSTITIAL ADS!!!

You can: log in, read the tech support FAQ, or request your lost password. This dumb message (and those ads) will appear on every screen until you register! Get rid of this crap by registering your own SA Forums Account and joining roughly 150,000 Goons, for the one-time price of $9.95! We charge money because it costs us money per month for bills, and since we don't believe in showing ads to our users, we try to make the money back through forum registrations.
 
  • Locked thread
Bob Morales
Aug 18, 2006


Just wear the fucking mask, Bob

I don't care how many people I probably infected with COVID-19 while refusing to wear a mask, my comfort is far more important than the health and safety of everyone around me!



This is my IBM. There are many like it, but this one is mine.
My IBM is my best friend. It is my life. I must master it as I must master my life.
Without me, my IBM is useless. Without my IBM, I am useless.

Are you also stuck using this worthless piece of poo poo? Let's talk here. We have some sort of modern stuff running on the iSeries under Zend PHP 6, which is kind of neat. But most of our poo poo is RPG spaghetti code that was written by a retarded monkey.

I'll kick the thread off with a quick question:

What's the best way to save a backup of an RPG source file before I start making changes so I can roll it back when all poo poo breaks loose?

Source control would be cool but I don't know if I want to integrate git or something because this box is going to be gone in a few months. I just want to do something like COPY FREIGHTCHG FREIGHTCHG.BACK
Edit: that was a dumb question, you just copy the member of the library and you get a new file to play with.

Bonus look at the code I'm working with:

code:
 428900      c     o1pgrp        ifeq      'SHOP'                                                                       08/06/14
 429000      c     h1sttx        ifeq      'NY'                                                                         08/06/14
 429100      c                   move      *blanks       cmnyu                                                          08/06/14
 429200      c                   movel     cmcctyu       cmnyu            12                                            08/06/14
 429300      c     cmcctyu       ifeq      'BRONX'                                                                      08/06/14
 429400      c     cmcctyu       oreq      'BROOKLYN'                                                                   08/06/14
 429500      c     cmcctyu       oreq      'MANHATTEN'                                                                  08/06/14
 429600      c     cmcctyu       oreq      'NEW YORK'                                                                   08/06/14
 429700      c     cmcctyu       oreq      'QUEENS'                                                                     08/06/14
 429800      c     cmnyu         oreq      'STATEN ISLAN'                                                               08/06/14
 429900      c                   z-add     *ZERO         W_FRT                                                          08/06/14
 430000      c                   z-add     *ZERO         W_FRTu                                                         08/06/14
 430100      c                   goto      endunit  
I wonder what shipments going to Manhattan get charged?
code:
438700      c*    o1pgrp        ifeq      'SHOP'                                                                       08/11/14
 438800      c     h1sttx        ifeq      'CT'                                                                         08/05/14
 438900      c     h1sttx        oreq      'LA'                                                                         08/05/14
 439000      c     h1sttx        oreq      'ME'                                                                         08/05/14
 439100      c     h1sttx        oreq      'TX'                                                                         08/05/14
 439200      c     totqtyu       ifeq      1                                                                            08/11/14
 439300      c                   z-add     120.00        W_FRT                                                          08/05/14
 439400      c                   z-add     120.00        W_FRTu                                                         08/05/14
 439500      c                   goto      endshp                                                                       08/07/14
 439600      c                   end                                                                                    08/05/14
 439700      c                   end                                                                                    08/05/14
 439800      C*                  END                                                                                    08/11/14
 439900      c*    o1pgrp        ifeq      'SHOP'                                                                       08/11/14
 440000      c     h1sttx        ifeq      'AL'                                                                         08/05/14
 440100      c     h1sttx        oreq      'AR'                                                                         08/05/14
 440200      c     h1sttx        oreq      'DE'                                                                         08/05/14
 440300      c     h1sttx        oreq      'GA'                                                                         08/05/14
 440400      c     h1sttx        oreq      'KS'                                                                         08/05/14
 440500      c     h1sttx        oreq      'MA'                                                                         08/05/14
 440600      c     h1sttx        oreq      'MD'                                                                         08/05/14
 440700      c     h1sttx        oreq      'MS'                                                                         08/05/14
 440800      c     h1sttx        oreq      'NC'                                                                         08/05/14
 440900      c     h1sttx        oreq      'NE'                                                                         08/05/14
 441000      c     h1sttx        oreq      'NH'                                                                         08/05/14
 441100      c     h1sttx        oreq      'NJ'                                                                         08/05/14
 441200      c     h1sttx        oreq      'OK'                                                                         08/05/14
 441300      c     h1sttx        oreq      'PA'                                                                         08/05/14
 441400      c     h1sttx        oreq      'RI'                                                                         08/05/14
 441500      c     h1sttx        oreq      'SC'                                                                         08/05/14
 441600      c     h1sttx        oreq      'SD'                                                                         08/05/14
 441700      c     h1sttx        oreq      'VA'                                                                         08/05/14
 441800      c     h1sttx        oreq      'VT'                                                                         08/05/14
 441900      c     totqtyu       ifeq      1                                                                            08/11/14
 442000      c                   z-add     115.00        W_FRT                                                          08/05/14
 442100      c                   z-add     115.00        W_FRTu                                                         08/05/14
 442200      c                   goto      endshp                 
Gah. This is manageable, I can go in and change states/shipping costs around. But coming from Python, PHP, whatever, it seems like it'd be easier to search an array then a big if/else block. I have a stack of crusty RPG tutorials from some seminar in 1988.

Bob Morales fucked around with this message at 01:11 on Sep 13, 2016

Adbot
ADBOT LOVES YOU

GreenNight
Feb 19, 2006
Turning the light on the darkest places, you and I know we got to face this now. We got to face this now.

I work at a company who has an AS400 and programmers to support it. I am not one of those programmers. We just got a new "AS400" which is a Power S814.

  • Locked thread