Understanding the DISPLAY ARRAY instruction

The DISPLAY ARRAY is a dialog instruction designed to browse a list of record, binding a static or dynamic array model to a screen array of the current displayed form.

Use the DISPLAY ARRAY instruction to let the end user browse in a list of rows, after fetching a result set from the database. The result set is produced with a database cursor executing a SELECT statement. The SELECT SQL statement is usually completed at runtime with a WHERE clause produced from a CONSTRUCT dialog. When the DISPLAY ARRAY statement completes execution, the program must test the INT_FLAG variable to check if the dialog was validated (or canceled) to take into account (or ignore) the row the was chosen by the user.

A DISPLAY ARRAY instruction supports additional features such as drag & drop, tree-view management, built-in sort and search, multi-row selection and list modification triggers. For a detailed description of these features, refer to the following topics of the DISPLAY ARRAY subdialog in the DIALOG instruction: