CSCI 320 Lab 5
 

A Third COBOL Program (using FTP and local editor)

 

  1. Using previous programs as models, write a program for the STUDENT-LISTING described below:

 

Input: STUDENT-DATA         StudentID  StudentName         Grade skip Hours

                                                 1           5   6                           25 26-27  28   29-30

 

 

Output:

STUDENT-LISTING, This should be a listing of all the students in the file.  If you have extra time calculate the class grade average .

 

 

This time enter the program on the local machine, and then send it to the VAX using ftp.  Open WordPad (or Notepad)

Use the following select statements:

            SELECT STUDENT-DATA     ASSIGN TO ‘LAB3.DAT’.

            SELECT STUDENT-LISTING ASSIGN TO ‘REPORT3.DAT’.

Save as: M: LAB3.COB (or whatever is your network drive) you may also use your flash drive

 

  1. Create the data file.  Open a clean page in WordPad. Type the following:

12339ABLE, SUSAN           35 03

14902MILLER, CARLOS        30 03

23961DIMSDALE, DARING      15 04

34500RICKELS, DON          20 02

            (be careful to adhere to the format above).

            Save as LAB3.DAT

  1. Move the files to the VAX.  Start the FTP program under the MSDOS command application:

C> M:

M>ftp cluster.edinboro.edu     (remember: ftp is a lower case world)

(login and password)

ftp> ascii

ftp> put m:/lab3.cob      (check for the transmission message to be sure it worked)

ftp> put m:/lab3.dat

ftp> dir                                    (this will list your files on the VAX, be sure they are there)

(minimize the ftp screen)

  1. Start a telnet session using TeraTerm or Putty.  Logon and run your program:

$ COBOL/LIS/WARNINGS=ALL   LAB3.COB

(If you have errors, you can fix them using EDIT/EDT as last week, or you can go back to your Notepad version, fix and resend using FTP screen).

            $ LINK LAB3

            $ RUN LAB3

  1. Print your results

Maximize the ftp screen and type:

ftp> get lab3.lis    (this will come to M drive)

ftp> get report3.dat

Send both files to the printer.