Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

i have a sequencial file contains multiple records, i want
to extract one row which contains various fields like order
number,date,warehouse,.ect.. in to the another file by
accepting the order number from jcl. how can i do it. pls
help me..

Answer Posted / sowjanya

let say ur input file is like below.
FD input-file.
01 input-record.
05 order-number pic x(5).
05 order-date pic x(10). etc.
the order number passed by the JCl willbe received in cobol
thru linkage section .let say that is LS-ORDER-NUMBER.

code like below in procedure division.
Procedure division.
Read input-file until EOF
at end move 'Y' to EOF.
if order-number = ls-order-number
write out-rec from input-record.

Here the out-rec contains only one record that has order
number equals to the order number received from JCL.

Is This Answer Correct ?    7 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is amode(24)?

1251


What is the default value(s) for an initialize? What keyword will allow for an override of the default?

1130


How do get the result of your program directly on your pc?

2352


What is rmode(any) ?

1280


what is s000 u4087 error? please give the all error codes in cobol,jcl.

17887


What is redefines clause in COBOL?

1301


Explain sorting techniques in cobol program? Provide the sort file definition, the sort statement, its syntax and meaning

1102


Why did you choose to work with ibm mainframe cobol programming?

1122


Difference between array and sub-script ?

1671


Can we change the password using ALTER? anyone tried and changed?

2023


how do you reference the ksds vsam file formats from cobol programs

1201


Whats the difference between search & search ALL?

6549


What is the difference between Call and a Link?

1205


Can a Search can be done on a table with or without Index?

1296


What is cobol?

1247