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



Hi Thomas -

On Fri, 27 Mar 2015 10:19:23 +0000, Thomas Raddatz
<thomas.raddatz@xxxxxx> wrote:

"If character, graphic, or UCS-2 fields are compared, fields of unequal length are aligned to their leftmost character. The shorter field is filled with blanks to equal the length of the longer field so that the field lengths are equal for comparison."

It does not explicitly mention varying fields and I completely agree for fix-length fields. But for varying fields, for example, a field with length = 0 is different from a field with one or more spaces.

What is your opinion about that?

My opinion is that it is working as designed.

If the values are equal after the field with the shorter varying
length is padded with spaces to be the same length as the field with
the longer varying length, then the fields are equal per the
documentation.

If you want to require that the varying lengths be equal, you need to
check that also:

if (%len(FieldA) = %len(FieldB)) and (FieldA = FieldB) ;

Also ... If the compiler was coded so that varying fields had to be
the same length to be considered equal, then people who didn't care
about the length being equal would have to move the varying fields to
fixed length fields to do a comparison. The way it is now is more
programmer-friendly.

Ken
Opinions expressed are my own and do not necessarily represent the views
of my employer or anyone in their right mind.

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.