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



I have always felt that what you have here, while technically incorrect, is outside the compiler's area of responsibility... Responsibility lies with the developer.

The "list of keys" (as referred to in the ILE RPG manual) seems to be treated similarly to a VALUE or CONST in a parameter list. The value will be reformatted if necessary to meet the requirements of the file description, and the operation will continue. In fact, that's one of the beautifull things about this (way-too-long-needed) method of access.

"Bryce Martin" <BMartin@xxxxxxxxxxxx> wrote:

So I think I have a type mismatch that should be caught at compile time

that isn't. The code has worked for sometime now and we just
discovered
what we thing "should" have been a compile error. Source compiles
fine,
program runs and acts "as expected". The problem comes in with a
logical
being used.

Field Defs.
QuoteNumber 9a
ItemNumber 15a
Quantity 11s 3


The logical is OEBOML1 with the following key...
OQUOTE 6a
OPROD 15a
OPQTY 11s 3
OSEQ 3s 0
OERQT 9a
OQTLN 3s 0

OQUOTE is the first 6 characters of the QuoteNumber - anyway... I have
this statement....

setll (QuoteNumber:ItemNumber:Quantity) oeboml1;
reade (QuoteNumber:ItemNumber:Quantity) oeboml1;
dow not %eof(oeboml1);

What I'm thinking is that I should get a compile error since
QuoteNumber
is 9a, not 6a. Shouldn't this be a key mismatch error?

But it doesn't error out. And, on top of that, when I run the code it
acts a I would "want" it to and finds the quotes properly.... at least
as
far as I can tell....

I'm really stumped as to why this "works".... any thoughts?


Thanks
Bryce Martin
Programmer/Analyst I
570-546-4777
--- This message (including any attachments) is intended only for the
use of the individual or entity to which it is addressed and may
contain information that is non-public, proprietary, privileged,
confidential, and exempt from disclosure under applicable law. If you
are not the intended recipient, you are hereby notified that any use,
dissemination, distribution, or copying of this communication is
strictly prohibited. If you have received this communication in error,
please notify us and destroy this message immediately. ---
--
This is the RPG programming on the IBM i / System i (RPG400-L) mailing
list
To post a message email: RPG400-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/rpg400-l
or email: RPG400-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/rpg400-l.

--
Sent from my Galaxy tablet phone with with K-9 Mail. Please excuse my brevity.

As an Amazon Associate we earn from qualifying purchases.

This thread ...

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.