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


  • Subject: RE: RPG400-L Digest V2 #238
  • From: "Dugas, Paul-Exch" <Dugas.Paul@xxxxxxxxxx>
  • Date: Fri, 7 Jul 2000 16:46:20 -0400

I'm not positive without looking at the compilation report, but doesn't a 4
dimension array create subscript 0,1,2,3 as opposed to 1,2,3,4?  You state
the values in your array of 1,2,3,4 but you set per = 0 so if I am correct,
you have an incorrect date in 
agedates(0).  Just a thought, but I'm a little array rusty.  Good Luck

Paul M. Dugas Jr.
EDI Programmer/Analyst
Pameco Corp     
1000 Center Place
Norcross, GA 30093
770/798-0700 phone(ext3401)
770/734-1008 fax
800/764-9307pager
dugas.paul@pameco.com
www.pameco.com

> ------------------------------
> 
> Date: Fri, 07 Jul 2000 11:08:40 -0700
> From: Jim Langston <jlangston@conexfreight.com>
> Subject: Bug in Lookup?
> 
> V3R7M0 RPG IV
> 
> I have some variables declared for a lookup table:
> D AgeDates        S               D   Dim(4) Inz(d'0001-01-01') Ascend
> D InvoiceDate     S               D   Inz(d'0001-01-01')
> D Per             S              3S 0 Inz(*Zero)
> 
> I have a routine that goes through these 4 dates and sets value for them,
> and in debug
> they show as:
> 
> > EVAL AgeDates
>   AGEDATES(1) = '2000-06-07'
>   AGEDATES(2) = '2000-05-08'
>   AGEDATES(3) = '2000-04-08'
>   AGEDATES(4) = '2000-03-09'
> 
> INVOICEDATE = '1994-01-07'
> 
> Then I get to the call:
> C                   Eval      Per = *Zero
> C     InvoiceDate   Lookup    AgeDates(Per)                        9999
> 
> I get an error.
> 
>  Message ID . . . . . . :   RNX0112
>  Date sent  . . . . . . :   07/07/00      Time sent  . . . . . . :
> 10:45:32
> Message . . . . :   Date, Time or Timestamp value is not valid.
> 
> Cause . . . . . :   The Date, Time or Timestamp value is not valid. Some
>   examples of values which are not valid are:
>     -- A date of 1994/02/31, which is not possible.
>     -- A time of 01/03:04, which does not have correct separators.
> Recovery  . . . :   Correct the value of the Date, Time or Timestamp
> field.
> 
> What, if anything, am I doing wrong?  And if I'm not doing anythign wrong,
> is this
> an RPG error?  Do I need to convert these dates to YMD numeric format
> instead?
> 
> Regards,
> 
> Jim Langston
> 
> ------------------------------
> 
> End of RPG400-L Digest V2 #238
> ******************************
> 
> +---
> | This is the RPG/400 Digest Mailing List!
> | To submit a new message, send your mail to RPG400-L@midrange.com.
> | To subscribe to this list send email to
> RPG400-L-DIGEST-SUB@midrange.com.
> | To unsubscribe from this list send email to
> RPG400-L-DIGEST-UNSUB@midrange.com.
> | Questions should be directed to the list owner/operator:
> david@midrange.com
> +---
+---
| This is the RPG/400 Mailing List!
| To submit a new message, send your mail to RPG400-L@midrange.com.
| To subscribe to this list send email to RPG400-L-SUB@midrange.com.
| To unsubscribe from this list send email to RPG400-L-UNSUB@midrange.com.
| Questions should be directed to the list owner/operator: david@midrange.com
+---

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:

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.