FOR get_products IN order_products LOOP
The FOR loop eliminates the use of OPEN, FETCH, and CLOSE statements.
It also eliminates the declaration of the variables for fetching the data. The FOR loop index get_products is implicitly declared as a record.
get_products.product_name
Dot notation is used to reference the product_name column within the cursor.
Simple FOR loops iterate over a specified range of integers (lower_bound .. upper_bound).
The number of iterations is known before the loop is entered. The range is evaluated when the FOR loop is first entered and is never re-evaluated.
If lower_ bound equals upper_bound, the loop body is executed once.
As Example 6 shows, the sequence of statements is executed once for each integer in the range 1 to 500. After each iteration, the loop counter is incremented.