| ||||||||||||
Product Details
|
sed & awk describes two text processing programs that are mainstays of the UNIX programmer's toolbox.
sed is a "stream editor" for editing streams of text that might be too large to edit as a single file, or that might be generated on the fly as part of a larger data processing step. The most common operation done with sed is substitution, replacing one block of text with another.
awk is a complete programming language. Unlike many conventional languages, awk is "data driven" -- you specify what kind of data you are interested in and the operations to be performed when that data is found. awk does many things for you, including automatically opening and closing data files, reading records, breaking the records up into fields, and counting the records. While awk provides the features of most conventional programming languages, it also includes some unconventional features, such as extended regular expression matching and associative arrays. sed & awk describes both programs in detail and includes a chapter of example sed and awk scripts.
This edition covers features of sed and awk that are mandated by the POSIX standard. This most notably affects awk, where POSIX standardized a new variable, CONVFMT, and new functions, toupper() and tolower(). The CONVFMT variable specifies the conversion format to use when converting numbers to strings (awk used to use OFMT for this purpose). The toupper() and tolower() functions each take a (presumably mixed case) string argument and return a new version of the string with all letters translated to the corresponding case.
In addition, this edition covers GNU sed, newly available since the first edition. It also updates the first edition coverage of Bell Labs nawk and GNU awk (gawk), covers mawk, an additional freely available implementation of awk, and briefly discusses three commercial versions of awk, MKS awk, Thompson Automation awk (tawk), and Videosoft (VSAwk).
Suggested Tags from Similar Products(What's this?)Be the first one to add a relevant tag (keyword that's strongly related to this product)
|
|
Share your thoughts with other customers:
|
||||||||||||||||||||||
|
Most helpful customer reviews
3.0 out of 5 stars
The best (only?) book to learn these tools from A to Z,
By Olivier Langlois "www.OlivierLanglois.net" (Montreal, Quebec Canada) - See all my reviews (REAL NAME)
This review is from: sed & awk (Paperback)
I had to do some text processing and I wanted to learn sed & awk so I picked this book that is, to my knowledge, the only book completely dedicated to these tools. The chapter on 'advanced' sed programming is very scary because when using 'advanced' sed features, the syntax is cryptic. It is nice to know that these features are there but I want to stay away from them and perhaps use awk or perl for the tasks that would require those 'advanced' features. Still, when you stick with the 'basic' and 'intermediate' sed features, you can do cool things easily in shell scripts.Overall, the book was not thrilling to read but it does a good job to teach you these text processing tools.
5.0 out of 5 stars
2 cute little guys that will work hard for you,
By
This review is from: sed & awk (Paperback)
I've had this book for 3-4 years now and find it to be mu handiest refernce. I even use ot more than my vi book.The raw power of sed and awk will humble even the proudest VB programmer and this book will help you get the most out of both the "Aho, Weinberg and Kernigan" and the "stream editor". The first chapter section is entitled "May You Solve Interesting Problems" a paraphrase of the old Chinese curse, but with sed and awk no problem seems insurmountable and wil make all problems appear interesting. This book is an outstanding reference and will get you up and running with both of these handy little programs in no time. Just to give you an example - the first time I ever used these programs (sed and awk) I developed a cron script to query a database every day at midnight, sort the results, grabbed lines with tagged values within certain limits, added a few totals, did some averaging, "starred" the lines that departed from certain parameters, then formatted the results into a report with a header showing the dates, times and query results, statistics then packed them into a report file and e-mailed them to a dozen recipients and added a few recipients if the data was outside certain values. I did this remarkable feat by copying a few examples from the book, changing a thing or two and in the end had a little shell script that was a few K-bytes at the most. This VB guy from corporate worked on a VB version of the same function and ended up with six revisions, several megs in the executable and never was able to get it formatted right. Not to say that it couldn't be done but..... I wrote mine before lunch one day. He worked on his for weeks and weeks. Such is the power contained within should you want to tap it Grasshopper. Great book. Amaze your friends and colleagues. Have the office women ( or men) throw flowers at your feet as you enter every day - well maybe not, but this will make you more productive. You real nerds will hardly get finished with a single box of Pop Tarts before you are writing really cool scripts when using this book. Like all O'Reilly books this one is terse, practical and highly usable - just like UNIX.
5.0 out of 5 stars
Good first book on Awk & Sed,
By
This review is from: sed & awk (Paperback)
This is a great first book on awk and sed. It also has one of the clearest explanations of regular expressions I could find. I use it all the time in my database programming/data processing work. It has served me well. There are probably more advanced features of awk that are not covered in this book but for the price it is a great bargain. If you want to learn awk buy this book and you won't be disappointed. You can ignore the sections on sed if you like.
Share your thoughts with other customers: Create your own review
Want to see more reviews on this item?
|
Most recent customer reviews |
|