×
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.
Don Wereschuk wrote:
DCheckField S 1A based(FieldToCheck) VARYING
My question is How do I define the varible CheckField so that when FieldToCheck points to a variable that is say 10A in length Checkfield will adjust accordingly. My understanding from the documentation is that by using BASED(pointer) it should adjust itself but that doesn't seem to be working that way
Don:
Keep in mind that if the field that is referenced by your pointer
isn't also a VARYING field, then all bets are off.
Back in some calling proc, there is an actual definition of some
memory. Think of that like an actual street address -- e.g., 1106 N.
3rd Av. The pointer indicates a physical street address, but it says
nothing about the structure at that address.
Now, in your called proc, you provide a description of that street
address -- e.g., the third house from the intersection on the east
side of the street. Your definition in the called proc needs to have
an indication of the structure that should exist at the address.
Your called proc doesn't need actual source code to state the
address explicitly since the pointer does that for you, but it does
need source code that describes the memory /appropriately/. You
wouldn't get far with a description that says "apartment 402 of the
complex that is third from the intersection on the east side of the
street".
You seem to be trying to reference fixed-length fields with
varying-length definitions. The memory isn't structured the same for
fixed- and varying-length fields.
Tom Liotta
As an Amazon Associate we earn from qualifying purchases.
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.