Scanning the Entire Librarian Master File for a Specific String
search cancel

Scanning the Entire Librarian Master File for a Specific String

book

Article ID: 27822

calendar_today

Updated On:

Products

Librarian

Issue/Introduction

How can the Entire Librarian Master file be scanned for a specific string

Environment

Release 4.4 

Resolution

Here is a sample job to scan a whole master file for a certain string. Replace the following:

  1. *search string* with the string needed to be searched for
  2. your.libr.master with the name of the Librarian master file
//LIB2         EXEC     PGM=AFOLIBR,PARM='DEPTH=25'
//MASTER       DD       DSN=your.libr.master,DISP=SHR
//OSJOB        DD       DUMMY
//LIST         DD       SYSOUT=*
//SYSPRINT     DD       SYSOUT=*
//SYSIN        DD       *
-OPT UTILITY
-SCAN *search string*
-END
 /*