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 sequential file. How do I access a record in this
sequential file randomly in my program ?

Answer Posted / harish

YS WE CANT ACCESS FLAT FILE RANDOMLY

IF WE WANT TO ACCESS PARTICULAR RECORD



PROCEDURE DIVISION.

MOVE KEYFIELD VALUE TO W-S VARIABLE
PERFORN UNTIL W-FLAG = 'Y'
READ FILE1 AT END MOVE 'Y' TO W-FLAG
NOT AT END
IF KEY-FILE1 = WS-KEY-VARIABLE
MOVE--------

ELSE
MOVE 'Y' TO W-FLAG.

pls correct me if anything wrong

HARISH POOMGAME SHIVAPPA(hassan,karnataka)
NIIT TECHNOLOGY
KOLKATA

Is This Answer Correct ?    0 Yes 12 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

how to access the file from prodution from changeman tool and to submit a file to production

7438


What is the difference between structured cobol programming and object alternativelyiented cobol?

1183


What are the different open modes available in cobol?

1142


What are the different rules to perform a Search?

1048


How do define dynamic array in cobol.

1081


What is the utilization of copybook in cobol? Could we utilize a similar copybook?

1174


Hi pls anybody tell me about " ANALYSIS DOCUMENT PREPARATION AND ESTIMATION OF TASK " (in real time project)."I want to update a sequential file in my project" for that purpose i need both structures i mean analysis document and estimation of task.

2078


A table has two indexes defined. Which one will be used by the SEARCH?

1229


How do define dynamic array in cobol. how do you define single dimensional array and multidimensional array in your cobol?

1185


What is Pic 9v99 Indicates in COBOL?

1176


can anybody post me about file-aid and changemen tools pls and give me reference if any mainframe guys are there

2323


What is the difference between Structured COBOL Programming and Object Oriented COBOL programming?

1053


Why is it necessary that file needs to be opened in I-O mode for REWRITE?

1256


i have 10 names in an array and my name is one of them also array is not in sorted order i need to display my name using index how will i do this

1465


When is inspect verb is used in cobol?

1179