Most Unix and GNU/Linux shells implement a flat variable namespace. Korn shell 93 implements a hierarchical variable namespace. This enabled the implementation of an aggregate definition for a shell variable to include subvariables called compound variables. This post tries to explain compound variables in some detail and demonstrate how useful they can be in when dealing with structured data.
I am a big fan of the POSIX.1 standard. The lastest version of this standard (IEEE Std. 1003.1-2008) was released in December 1st 2008. The formal name for this version of the standard is Portable Operating System Interface (POSIX) Base Specifications, Issue 7. Like its predecessors, IEEE Std. 1003.1-2004 and IEEE Std. 1003.1-2001, it was developed by the Austin Common Standards Revision Group (CSRG), more commonly called the Austin Working Group, which is a joint technical working group established in 1999 to develop and maintain the core open systems interfaces. The working group’s stated approach to specification development is write