O'Reilly logo

Learning AWK Programming by Shiwang Kalkhanda

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Matching a string as sub-string only using

This matches the string enclosed between \B and \B as a sub-string. It is the opposite of \y. For example, \Bstart\B will match bigstarting, but not start or starting, as follows:

$ awk '/\Bstart\B/'  gopr.txt

The output on execution of the preceding code is as follows:

bigstarting

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required