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



 >> The DS is externally described and exists solely so that I can reference
the prototype fields back to the data file. 

This seems like a good idea until you encounter the kinds of problems you
are seeing!  In practice using LIKE on protos is probably not a good idea on
the whole.

The problem is basically a simple one.

Assume two fields in the file.

F1 is packed, and F2 is zoned.

Define an external DS based on this field and in that DS.F1 is packed and
DS.F2 is zoned.

Define the actual file itself on an F-spec however and _both_ File.F1 and
File.F2 will be zoned.

So if you say LIKE(DS.F2) in a prototype you just told the compiler to
define the parm as zoned.  However, try to pass File.F2 and you will get a
parm mis-match since it is a zoned field.


The cure is either to stop doing it and hard code the desired parameter
characteristics, use CONST on the prototype, or always define an external
non-qualified DS based on the file in the program so that the input field
format will match.


Jon Paris
Partner400

www.Partner400.com
www.RPGWorld.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.