What is difference between Write(1) and WRITE WORK FILE 1 ?



Software AG's platform-independent programming language with full support for open-source and Internet applications

What is difference between Write(1) and WRITE WORK FILE 1 ?

Postby diptisaini » Tue May 04, 2010 10:45 am

WRITE (1) NOTITLE 'REPORT' 8T 'KL0617'
42T #P-REPORT-TITLE
94T 'TIME:' 100T *TIMX(EM=HH':'II)
110T 'DATE:' 116T #P-BUS-DATE /
47T 'INCOMING MESSAGE QUEUE ERROR REPORT' //
'MESSAGE SEQ NO' 17T 'TRN' 36T 'ERROR CODE' 48T
'MESSAGE' 80T 'TRADE REF' 92T 'GTI' 105T
'DATE RECEIVE' 120T 'TIME RECEIVE' / "="(132)
'TIME RECEIVE' / '='(132)


WRITE WORK FILE 1 VARIABLE
'MSG TYPE'
',' 'SEQ NO'
',' 'TRN'
',' 'TRN (2-9)'
',' 'ERROR CODE'
',' 'ERROR MESSAGE'
',' 'TRADE REF'
',' 'GTI'
diptisaini
 
Posts: 90
Joined: Sun Mar 14, 2010 5:12 pm
Has thanked: 0 time
Been thanked: 0 time

Re: What is difference between Write(1) and WRITE WORK FILE 1 ?

Postby RGZbrog » Tue May 04, 2010 11:03 am

WRITE(1) writes a report line to DDNAME CMPRT01, which may be defined as SYSOUT or a dataset. Natural will perform pagination automatically. The format of the line can be controlled programmatically with edit masks, tabs, line breaks, etc.

WRITE WORK FILE 1 writes a data record to DDNAME CMWKF01.

Both the report line and the data record are defined with a set of fields.
User avatar
RGZbrog
 
Posts: 101
Joined: Mon Nov 23, 2009 1:34 pm
Location: California, USA
Has thanked: 0 time
Been thanked: 0 time

Re: What is difference between Write(1) and WRITE WORK FILE 1 ?

Postby diptisaini » Tue May 04, 2010 3:52 pm

Thanks for clearing my doubt.
diptisaini
 
Posts: 90
Joined: Sun Mar 14, 2010 5:12 pm
Has thanked: 0 time
Been thanked: 0 time

Re: What is difference between Write(1) and WRITE WORK FILE 1 ?

Postby helenwh » Wed Sep 01, 2010 2:58 pm

Hi RGZbrog! you have just make a clear explanation about the differences between Write(1) and WRITE WORK FILE 1. I absolutely agree with you and highly appreciate your contribution.
helenwh
 
Posts: 1
Joined: Wed Sep 01, 2010 2:23 pm
Location: Singapore
Has thanked: 0 time
Been thanked: 0 time


Return to Natural

 


  • Related topics
    Replies
    Views
    Last post