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

The time function

This section discusses the built-in time functions available in AWK. There are three functions that come under the category of time function, named systime(), mktime(datespec), and strftime(format,timestamp). With the help of these AWK functions, we can produce useful reports with timestamps. On POSIX-compliant Unix/Linux systems, the time() system call is generally used, which returns the number of seconds since the epoch (1970-01-01 00:00:00 UTC).

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