cobol 85 , carriage return and line feed

1k views Asked by At

I am coding in cobol85, I have an input file having 2 records as of now

""1";"S";"20140211095016";;;;;"KANATA";"ON";"K2V 1A5";"ZR1
;;;;;;;;;;"-503.15";;"1715.27";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"26696.33
";"78.22";"3275.95";;;;;"30050.50";;" 
""1";"S";"20140211088445";;;;;"MANATA";"ON";"K2V 1A5";"ZR1
;;;;;;;;;;"-503.15";;"1715.27";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"26696.33
";"78.22";"3275.95";;;;;"30350.50";;" 

I am reading this input record and I want to put each record into different variables as of no into two different variables by inspecting carriage return or/and line feed but how can I do it I tried using "X'ODOA' but I couldn't separate it. Please help me how should I inspect and separate the records.

1

There are 1 answers

4
Molusco On

I am asuming the first record finishes at "30050.50";;" and the second one starts at ""1";"S"

If those are two separate records on a sequential file you don't need to inspect for CR or LF as each READ will read a new line.

Can you post the SELECT and FD of that file?