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



Hello.

Your PGMA is reading the file the fastes way it can be done, if your 
intention is to read trough the whole file sequentially.

Your PGMB defines the file as indexed with dynamic access.  If you are 
going to read one and one record by key, this is the way to define the 
file.  But we don't see any file access in PGMB, only a definition.

PGMB calls PGMC, and it is the same here, we don't see any programmed file 
access, only the definition of the file.

Execution time will higly depend upon the way you use open/close, and the 
way you read the file by key.  You probably don't have to worry about your 
sequential read in PGMA, but consentrate on PGMB/PGMC. 


Mvh.

Geir Kildal
TietoEnator AS





cobol400-l@xxxxxxxxxxxx 
Sent by: cobol400-l-bounces@xxxxxxxxxxxx
14.04.2005 05:06
Please respond to
COBOL Programming on the iSeries/AS400 <cobol400-l@xxxxxxxxxxxx>


To
COBOL Programming on the iSeries/AS400 <cobol400-l@xxxxxxxxxxxx>
cc

Subject
[COBOL400-L] Read same file






Hello,
 
I am new to the AS400.  I have 3 programs that using the same file but
different Access mode.

       IDENTIFICATION DIVISION. 
       PROGRAM-ID.  PGMA. 
       :
       SELECT FILEA ASSIGN TO DATABASE-FILEA 
           FILE STATUS IS STATUS-A 
           ACCESS MODE IS SEQUENTIAL 
           ORGANIZATION IS SEQUENTIAL. 
       :
       10-READ-A.
           READ FILEA.
           IF STATUS = "00"
              CALL "PGMB" USING PARM1
              Go To 10-READ-A.
       10-READ-A-X. EXIT.

       IDENTIFICATION DIVISION. 
       PROGRAM-ID.  PGMB. 
       :
       SELECT FILEA ASSIGN TO DATABASE-FILEA 
           FILE STATUS IS STATUS-A 
           ACCESS MODE IS DYNAMIC 
           ORGANIZATION IS INDEXED 
           RECORD KEY IS EXTERNALLY-DESCRIBED-KEY. 
       :
       CALL "PGMC" USING PARM2.

       IDENTIFICATION DIVISION. 
       PROGRAM-ID.  PGMC. 
       :
       SELECT FILEA 
           ASSIGN TO DATABASE-FILEA 
           FILE STATUS IS STATUS-A 
           ACCESS MODE IS DYNAMIC 
           ORGANIZATION IS INDEXED 
           RECORD KEY IS EXTERNALLY-DESCRIBED-KEY. 


PGMA is read FILEA one by one.
My problem is the process time for complete the program PGMA is too long.
Could someone help me, how the 
accelerate the process .

rgds
Agus R

IMPORTANT NOTICE: 

The information in this email (and any attachments) is confidential. 
If you are not the intended recipient, you must not use or disseminate the
information.
If you have received this email in error, please immediately notify me by
"Reply" command 
and permanently delete the original and any copies or printouts thereof. 
Although this email and any attachments are believed to be free of any 
virus
or 
other defect that might affect any computer system into which it is 
received
and opened, 
it is the responsibility of the recipient to ensure that it is virus free
and no responsibility 
is accepted by American International Group, Inc. or its subsidiaries or
affiliates either 
jointly or severally, for any loss or damage arising in any way from its
use.
_______________________________________________
This is the COBOL Programming on the iSeries/AS400 (COBOL400-L) mailing 
list
To post a message email: COBOL400-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/cobol400-l
or email: COBOL400-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/cobol400-l.



As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

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.