You can use the reportLib.fillReport() function to fill a report using a specified data source.
reportLib.fillReport(
report Report in,
source DataSource in)
// an array of records, with data
myRecords customerRecord[];
eglReportData.data = myRecords;
The following example shows the code to fill a report using an SQL statement:
reportLib.fillReport (eglReport, DataSource.sqlStatement);