× 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.



This is a multipart message in MIME format.
--
[ Picked text/plain from multipart/alternative ]
Steve,

Bummer about your pointy haired boss locking into RPG400 as a shop
standard.  I wonder if he's one that is afraid that one might surpass him?

I am a little spoiled here regarding PC's.  Work has given me three:  two
on my desk and one at home.  It's really cool when they walk up and ask
you if you want an upgrade and you haven't opened up a peep.  And if you
do request it "I've got this problem with iSeries Navigator and IBM thinks
I need more memory.  They're full of sh!t, it's something else, but I want
more memory to remove this standard argument from them.", they get you the
memory quick.

Rob Berendt
--
"They that can give up essential liberty to obtain a little temporary
safety deserve neither liberty nor safety."
Benjamin Franklin




"Steve Landess" <steve_landess@hotmail.com>
Sent by: rpg400-l-admin@midrange.com
10/15/2002 01:15 PM
Please respond to rpg400-l


        To:     <rpg400-l@midrange.com>
        cc:
        Fax to:
        Subject:        Re: handling date data types


Dave,

When you have a file that has a date, time, or timestamp field defined,
you
must compile the RPG400 program with CVTOPT(*DATETIME) when you use
CRTRPGPGM.  RPG/400 will then treat the date/time/timestamp fields as
character fields.

Then, in the program, you can reference the date field as a 10-byte
character field.  Just move this field to a data structure or substring
out
the month, day, or year values from the appropriate positions in the
character field.

Just remember that if you attempt to update the value in the field, you
must
ensure that you have the date formatted properly.  Otherwise the UPDATE
operation will fail with a CPF5035 error (Data mapping error on member
xxxxx).  DB2/400 will ensure that the value that you use is valid before
it
will let you update the date field in the database file.

HTH

And by the way, Rob:

I still use RPG400 because it is the shop standard in the shop where I am
working.  I am trying my best to learn ILE and RPGIV stuff on the side,
but
I can't just start using it in production because it is the "best" way to
write code.  Sometimes you have to just work within the framework that you
are given.

Likewise, I would love to start working in CODE/400 (again--It has to be
better now than it was 8 years ago when I first tried it..).  However, my
workstation couldn't run it if I wanted to...my Pentium 200 desktop system
is vintage and has neither the speed, memory or disk space to run/load
it...


----- Original Message -----
From: "Prowak, Dave" <DProwak@ci.syracuse.ny.us>
To: <rpg400-l@midrange.com>
Sent: Tuesday, October 15, 2002 11:07 AM
Subject: handling date data types


Hi,

Is it true that using RPG400 it is NOT possible to extract the month, day
or
year from
a date data type?

Dave
_______________________________________________
This is the RPG programming on the AS400 / iSeries (RPG400-L) mailing list
To post a message email: RPG400-L@midrange.com
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/cgi-bin/listinfo/rpg400-l
or email: RPG400-L-request@midrange.com
Before posting, please take a moment to review the archives
at http://archive.midrange.com/rpg400-l.

_______________________________________________
This is the RPG programming on the AS400 / iSeries (RPG400-L) mailing list
To post a message email: RPG400-L@midrange.com
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/cgi-bin/listinfo/rpg400-l
or email: RPG400-L-request@midrange.com
Before posting, please take a moment to review the archives
at http://archive.midrange.com/rpg400-l.





As an Amazon Associate we earn from qualifying purchases.

This thread ...


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.