× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



Rick,

What version of the OS are you running? Newer versions of the OS have a
command called RUNSQL. With that command you can easily run
UPDATE MYFILE SET THATDATE=THATDATE + 1 YEAR
If its a numeric or character pretending to be a date field then there's a
few more considerations that you have to handle manually, like adding a
year to 20120229.

If you have an older version of the OS and do not have this command it's
not too hard to find a 'roll your own' version on the internet. The
appearance of this command is not dependent on having 57##ST1 loaded.

There is a command called STRSQL. It does require that you have 57##ST1
loaded. If you have that command and aren't using it, well, you're about
to embark on a fun new path and you're not in Kansas anymore.

I know that some people look at graphical user interfaces like they're the
tool of the devil but there is something called "System i Navigator".
Buried within it is something called "Run SQL Scripts" and you can easily
run that sql command from within that. This doesn't matter if you have
57##ST1 loaded or not.

You can also bury that command into a source member and use the command
RUNSQLSTM.

For a tutorial on SQL I used "SQL/400 Developer's Guide" by Paul Conte and
Mike Cravitz. It's rather dated but still a good training start.


Rob Berendt

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.