Training

 

 

Popular Courses

Browse Our Free Resources

  • whitepapers
  • whitepapers
  • webinars
  • blogs

Our Locations

Training Centres

Vancouver, BC
Calgary, AB
Edmonton, AB
Toronto, ON
Ottawa, ON
Montreal, QC
Hunt Valley
Columbia

locations map

Calgary

550 6th Av SW
Suite 475
Calgary, AB
T2P 0S2

Toronto

821A Bloor Street West
Toronto, ON
M6G 1M1

Vancouver

409 Granville St
Suite 902
Vancouver, BC
V6C 1T2

U.S. Office

436 York Road
Suite 1
Jenkintown, PA
19046

Other Locations

Dallas, TX
Miami, FL

Home > Training > Unix > AWK Programming Training

AWK Programming Training

Course#: WA1194

The objective of this course is to develop the advanced skills required to write applications using the awk programming language.

Topics
 
  • Getting Started with awk
  • Regular Expressions
  • Reading Input Files
  • Printing Output
  • Expressions
  • Patterns, Actions, and Variables
  • Arrays in awk
  • Functions
  • Internationalization with gawk
  • Advanced Features of gawk
  • Running awk and gawk
  • A Library of awk Functions
  • Practical awk Programs
  • Internetworking with gawk
Audience
  Unix system application developers, administrators, and advanced users.
Prerequisites
  The ability to write programs in a high level language (such as C or shell) is very helpful in completing the lab exercises and understanding the lectures. A good working knowledge of the UNIX environment is necessary.
Duration
  Three days.

Outline of WA1194 AWK Programming Training

1. Getting Started with awk

 

  • How to Run awk Programs
  • Datafiles for the Examples
  • Some Simple Examples
  • An Example with Two Rules
  • A More Complex Example
  • awk Statements Versus Lines
  • Other Features of awk
  • When to Use awk

 

2. Regular Expressions

 

  • How to Use Regular Expressions
  • Escape Sequences
  • Regular Expression Operators
  • Using Character Lists
  • gawk-Specific Regexp Operators
  • Case Sensitivity in Matching
  • How Much Text Matches?
  • Using Dynamic Regexps

 

3. Reading Input Files

 

  • How Input Is Split into Records
  • Examining Fields
  • Non-constant Field Numbers
  • Changing the Contents of a Field
  • Specifying How Fields Are Separated
  • Reading Fixed-Width Data
  • Multiple-Line Records
  • Explicit Input with getline

 

4. Printing Output

 

  • The print Statement
  • Examples of print Statements
  • Output Separators
  • Controlling Numeric Output with print
  • Using printf Statements for Fancier Printing
  • Redirecting Output of print and printf
  • Special Filenames in gawk
  • Closing Input and Output Redirections

 

5. Expressions

 

  • Constant Expressions
  • Using Regular Expression Constants
  • Variables
  • Conversion of Strings and Numbers
  • Arithmetic Operators
  • String Concatenation
  • Assignment Expressions
  • Increment and Decrement Operators
  • True and False in awk
  • Variable Typing and Comparison Expressions
  • Boolean Expressions
  • Conditional Expressions
  • Function Calls
  • Operator Precedence (How Operators\ Nest)

 

6. Patterns, Actions, and Variables

 

  • Pattern Elements
  • Using Shell Variables in Programs
  • Actions
  • Control Statements in Actions
  • Built-in Variables

 

7. Arrays in awk

 

  • Introduction to Arrays
  • Referring to an Array Element
  • Assigning Array Elements
  • Basic Array Example
  • Scanning All Elements of an Array
  • The delete Statement
  • Using Numbers to Subscript Arrays
  • Using Uninitialized Variables as Subscripts
  • Multidimensional Arrays
  • Scanning Multidimensional Arrays
  • Sorting Array Values and Indices with gawk

 

8. Functions

 

  • Built-in Functions
  • User-Defined Functions

 

9. Internationalization with gawk

 

  • Internationalization and Localization
  • GNU gettext
  • Internationalizing awk Programs
  • Translating awk Programs
  • A Simple Internationalization Example
  • gawk Can Speak Your Language

 

10. Advanced Features of gawk

 

  • Allowing Nondecimal Input Data
  • Two-Way Communications with\ Another\ Process
  • Using gawk for Network Programming
  • Using gawk with BSD Portals
  • Profiling Your awk Programs

 

11. Running awk and gawk

 

  • Invoking awk
  • Command-Line Options
  • Other Command-Line Arguments
  • The AWKPATH Environment Variable
  • Obsolete Options and/or Features
  • Known Bugs in gawk

 

12. A Library of awk Functions

 

  • Naming Library Function Global\ Variables
  • General Programming
  • Datafile Management
  • Processing Command-Line Options
  • Reading the User Database
  • Reading the Group Database

 

13. Practical awk Programs

 

  • Running the Example Programs
  • Reinventing Wheels for Fun and Profit
  • A Grab Bag of awk Programs

 

14. Internetworking with gawk

 

  • Networking with gawk
  • Some Applications and Techniques
  • Related Links
We regularly offer classes in these and other cities. Atlanta, Austin, Baltimore, Calgary, Chicago, Cleveland, Dallas, Denver, Detroit, Houston, Jacksonville, Miami, Montreal, New York City, Orlando, Ottawa, Philadelphia, Phoenix, Pittsburgh, Seattle, Toronto, Vancouver, Washington DC.
*Your name:

*Your e-mail:

*Phone:

*Company name:

Additional notes:

We have received your message. A sales representative will contact you soon.

Thank you!.

more details
buy this course

Register for a courseware sample

It's simple, and free.

 

Thank You!

You will receive an email shortly containing a link to download the requested sample of the labs for this course.