Image description

The image is a flow chart that describes the program flow for the sample RPG program.

The following steps are what the flow chart follows:
  1. Begin
  2. Prompt
  3. F3? (*IN98) If Yes - End Program. If No, go to step 4.
  4. F2? (Review last) If Yes - go to step 4.a. If No, go to step 5.
    1. Read last record for this user.
    2. Record found? If Yes go to step 4.c. If No, go to step 4.d.
    3. Display Last transaction. Go to Begin.
    4. Display error. No review record. Go to Begin.
  5. Read product record.
  6. Found? If Yes, go to step 8. If No, go to step 7.
  7. Display error. No product record. Go to Begin or step 8.
  8. Check quantity on hand.
  9. Sufficient? If Yes, go to step 10. If No, go to step 9.a.
    1. Release lock on product record
    2. Display error. Not enough quantity. Go to Begin.
  10. Update product record.
  11. Write transaction record.
  12. Commit. Go to Begin.