set_sql
set_sql
set_sql(string $sql)
Parameter | Description |
---|---|
$sql | The SQL select query, which you want to use as the data source of your report. |
$report = new ReportOptions(SRE_PUBLIC_REPORT, SRE_SQL,"SQL_01");
$report->set_sql("select * from items where `Units_In_Stock` < 15 ")
->set_header("Header goes here")
->set_footer("Footer goes here")
->set_grouping(array("country"))
->select_all_fields();
$engine = new CustomEngine($report);
$report_path = $engine->create_report();