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



Jon,

you are completely right, CLEAR resets the value blank/null according to
field types and
RESET sets x'40404040' even into packed numeric fields if they are in a DS
and don't
have a INZ keyword or the DS has a general INZ attribute.

RESET also works with initial field settings in *INZSR and in any other use
of RESET it
resets the values like CLEAR does if the field dosn't have a INZ keyword..

Tell me if that is logical and/or tell me where and when you has the use
for your non-INZ
fields other than alphanumeric fields ends up containing garbage that even
may cause
the program to fail.



On Wed, Feb 15, 2012 at 2:55 PM, Jon Paris <jon.paris@xxxxxxxxxxxxxx> wrote:


On Feb 15, 2012, at 3:55 AM, rpg400-l-request@xxxxxxxxxxxx wrote:

This is more likely a data structure behavior problem because a unicode
fields starts it's "life" with complete different values based on whether
they
are defined as a free field or in a data structure.

EVAL yyy:x
00000 00200020 00200020 00200020 00200020
00010 00200020 00200020 00200020 00200020
EVAL ccc:x
00000 40404040 40404040 40404040 40404040
00010 40404040 40404040 40404040 40404040

Which is exactly what I would have expected. All fields in a DS are always
initialized to spaces (and always have been) unless either the DS has an
INZ or an individual field has one. Similarly a clear of a DS will
initialize fields to appropriate defaults based on data type. The rules for
standalone fields are different and they are always initialized to a
suitable default for their data type.

Jon Paris

www.partner400.com
www.SystemiDeveloper.com




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





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.