HOWTO Working with reports in Lianja 9.4
by
, 2023-10-04 at 05:33 (25852 Views)
A Visual Report Builder is a tool that allows you to create and customize reports from your data without coding. You can use a visual report builder to:
- Visualize data in different ways, such as charts, graphs, maps, tables, and more. Visualizing your data can help you discover patterns, trends, and insights that are not easily seen in raw numbers or text.
- Analyze your data from different sources, such as forms, surveys, databases, spreadsheets, or online services. You can filter, sort, group, and aggregate your data to get the information you need. You can also perform calculations and apply formulas to your data.
- Share and present your reports with others, such as your colleagues, clients, or audience. You can export your reports as PDF, EXCEL, ADO, JSON, XML or HTML files. You can also print your reports, email them or display them on a screen.
The Reports Workspace in the Lianja App Builder provides a full blown Report Builder that handles master/detail reports and is jam-packed full of features and functionality to help you be more productive.
If you need to create paginated reports for printing or generating PDFs, then the Lianja Report Builder is a good option.
Designing a Report
You design reports visually in the Lianja Report Builder.
- Create paginated reports with tables, charts, and free-form report layouts.
- Create tabular reports for column-based data, chart reports for graphical data, and free-form reports for anything else.
- Reports can embed other reports, charts, and images, .
- Report from a variety of data sources. You can create reports that combine data from any other databases using Lianja Virtual Tables. Use the Report Builder with Lianja, MSSQL, MySQL, VFP and other data sources.
- Using the Report Builder you can filter, group, and sort data, or add expressions for custom calculations.
- Summarize data in a visual format with charts, and present large volumes of aggregated information at a glance.
- Embed or reference images and other resources, including external content.
Documentation on the Report Builder can be found at:
https://www.lianja.com/doc/index.php/Reports_Workspace
Once a report has been designed you can print reports or save them as a pdf file which can be emailed.
The Report Viewer
The report viewer can be used to dynamically generate a named report, filter the records selected, print the report or email it.
You activate the Report Viewer using Lianja.showReportViewer().
Lianja.showReportViewer(cReportName [, cPrintArgs [, cTitle [, cFilter [, bCanFilter [,bCanEmail] ] ] ] ])
- cFilter is a where condition e.g. “orderid=10428”
- if bCanFilter is true then a “Filter” button allows use of the Query Builder to filter the records selected
- If bCanEmail is true then an "Email" is displayed
cReportName may be:
- The name of a report designed in the Report Builder
- The name of a .rsp, .pysp or .jssp file that will dynamically generate the HTML to be printed
Example:
Code:Lianja.showReportViewer("ordersummary")
You can specify a condition to filter and restrict the records selected in the report like this.
Code:Lianja.showReportViewer( "ordersummary", "", "Order Summary for 10249", "orderid=10249", false, false)
You can filter and email reports.
Clicking the "Email" button allows you to compose an email message and the report will be sent as an attachment.Code:Lianja.showReportViewer( "ordersummary", "", "Order Summary", "", true, true)
Printing a Report
You can use Lianja.printReport() to print directly to a printer:
Lianja.printReport(cReportName [, cPrintArgs [, lPreview[, cFilter]]] )
Example:
Lianja.printReport("ordersummary","", true, "orderid=10249")
Emailing a Report
Exporting a ReportCode:Lianja.emailReport(cReportName, cFilter, cEmailto, cEmailfrom, cSubject, cBody)
cExportType can be any of these export types:Code:Lianja.exportReport(cReportName, cExportType, cOutputfilename, cFilter)
csv
xml
json
excel
ado
html