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

Next usage

The next command is also used to change the flow of an AWK program. It causes the AWK to stop processing the current input record or pattern space and go on to next record. The program reads the next line and starts executing the commands again with the newline.

If we consider the analogy of AWK program execution with a loop that reads an input record and then performs the pattern matching against it, then the next statement is equivalent to the continue statement. It skips to the end of the body of the loop and begins the next iteration. Similarly, on getting next statement execution, the remaining AWK commands are not processed for current input record. The next input record is read and the execution of the AWK command in the ...

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