Populate a dataset using FILL
- Last Updated: January 22, 2026
- 2 minute read
- OpenEdge
- Version 12.8
- Documentation
After you define a dataset and its data-sources, the next step
is to populate the dataset with data. The simplest and most effective way to populate a
dataset is with the FILL( ) method. The FILL method not only populates the dataset from the data-sources you
attach, the method also coordinates the loading of data and maintains the integrity of
your data-relations.
In a single operation the FILL
method:
- Retrieves one or more top-level records from the defined data-sources
(using
NO-LOCK). - Retrieves all the related records (based on the data-relations
specified) from the defined data-sources (using
NO-LOCK). - Adds the retrieved records to the dataset.
When FILL executes, the method starts at
a top-level table, retrieves a single parent record and then traverses through all the
child records, filling each one with records related to the current parent record. Then,
the method retrieves the next parent record and the process continues through all
parent-child records. FILL uses the data-relations to
identify and load the child records for each parent. The following is the syntax for the
FILL statement:
|
The following example shows how to call the FILL method on a dataset:
|
Record access after the FILL
After the FILL method executes, and the temp-tables are populated, you
can access the data in the temp-tables using normal ABL syntax. In the following
example, immediately after FILL executes, a FIND FIRST
statement is called on the ttOrder temp-table which is
part of the dsOrderOrderLine dataset.
|
I
See also
Populate a ProDataSet in Use ProDataSets
Fill the entire ProDataSet in Use ProDataSets
Partially fill a ProDataSet in Use ProDataSets