Procedure Blocks and Data Access

In the first three sections of this book, you learn about the basic structure of ABL and many of its language constructs. This section returns you to writing ABL procedures on your own. These procedures contain some business logic that demonstrates in detail a few of the concepts touched on in the previous sections.

The important concepts of this section are ones you've already seen in action and learned something about. Indeed, as discussed with the very simplest ABL procedure—FOR EACH Customer: DISPLAY Customer.—you can hardly write any ABL code at all without defining blocks and using data access statements.

Nonetheless, this section goes into a lot more detail in these areas so that you have a more thorough understanding of these basic building blocks of ABL procedures. This section describes:

  • All the basic syntax for defining blocks of various kinds in the language, including some that iterate through a set of statements and some that just group them as a common action
  • The scoping of blocks and of the variables and objects you define in them and how scoping affects the way your procedures behave
  • A variety of ways to access database data and integrate it into your procedures