Re: dds-all-formats
- From: Frederico Fonseca <real-email-in-msg-spam@xxxxxxxxx>
- Date: Fri, 23 Mar 2007 01:18:26 +0000
On Wed, 21 Mar 2007 13:36:46 +0100, "josephit" <dakron@xxxxx> wrote:
Could you tell me what this realy mean with COPY and database file? I haveThis is a common format used on OS400 compilers.
this pice of code:
FD Mydatabase
LABEL RECORDS STANDARD.
01 R-Mydatabase.
COPY DDS-ALL-FORMATS OF Mydatabase.
AS400 files, being it "data" files, report files or screen files, can
have several "formats" although these are mainly used on screen and
report files.
The files can also have "indicatores" which are used to setup strings,
protection flags and other attributes on the files (screens mainly,
but reports also).
So a screen would for example have the following common formats.
output
input
indicatores.
Most people elect to retrieve the indicatores separately as it is
easier to deal with, but lets leave these out for now.
when related to "data" files you can have the following on a DDS.
(converted to COBOL. not in a mood to give a full DDS layout.
01 client-record.
05 client-number pic x(10)
05 client-name pic x(40).
01 agent-record.
05 agent-number pic x(10).
05 agent-type pic x(1).
05 sales-area pic x(10).
When doing a copy DDS-ALL-FORMATS that is what the compiler will
retrieve from the file definition and place on your program
If instead you used copy DDS-AGENT-RECORD (or something similar, cant
remember now), then only the agent-record layout would be retrieved,
and written to the file should you update it.
This is also requires the use of a indicator/record type to tell the
file manager what type of record is being inserted/updated to the
file.
Really a short explanation, and you are better off searching the
online manuals on IBM as others have mentioned.
This means that the fi
Frederico Fonseca
ema il: frederico_fonseca at syssoft-int.com
.
- Follow-Ups:
- Re: dds-all-formats
- From: Frederico Fonseca
- Re: dds-all-formats
- References:
- dds-all-formats
- From: josephit
- dds-all-formats
- Prev by Date: Re: data type conversion- help needed
- Next by Date: Re: dds-all-formats
- Previous by thread: Re: dds-all-formats
- Next by thread: Re: dds-all-formats
- Index(es):