Need to get a field into a data area. - IBM AS400
This is a discussion on Need to get a field into a data area. - IBM AS400 ; What would be the preferred method of doing this. I have a 4 field
database file where I need one field of the database into a data area
where the data area will be used for some other process....
-
Need to get a field into a data area.
What would be the preferred method of doing this. I have a 4 field
database file where I need one field of the database into a data area
where the data area will be used for some other process.
-
Re: Need to get a field into a data area.
On Jul 24, 12:15*pm, iseriesflorida wrote:
> What would be the preferred method of doing this. *I have a 4 field
> database file where I need one field of the database into a data area
> where the data area will be used for some other process.
You can manipulate data areas with programs. In RPGLE using the IN
and OUT commands. You'll have to define the data area in the
program. With CL programs look at RTVDTAARA and CHGDTAARA.
HTH,
Thad Rizzi
-
Re: Need to get a field into a data area.
Another option is to use APIs: QWCRDTAA reads DTAARAs, and they can be
written to using QCAPCMD or QCMDEXC (to call the CHGDTAARA command).
I'm puzzled why the other process doesn't just read the database file
where the field originally sits though. (Duplicating data might solve
your problem, but it does introduce risks of its own.)