Script and Comments
Script1 [ 1] /PAT/!d
[ 2] N;N;N
| |
Description
Assume that datafile contains 4-line records.
Each record keeps (Dept,ID,Name,Age).
Now we want to list all the records where 'Dept=MIS'.
|
| Raw Input
|
| Desired Output
| Dept=MIS
ID=00154
Name=John
Age=23
Dept=ACCOUNTING
ID=00312
Name=Mary
Age=26
Dept=SALES
No=00439
Name=Tom
Age=30
Dept=MIS
No=00183
Name=Ruth
Age=25
|
| Dept=MIS
ID=00154
Name=John
Age=23
Dept=MIS
No=00183
Name=Ruth
Age=25
|
|