Internal Database

The MasonSQL component /opt/masonsql/htdocs/lib/dbms_library.comp makes SQL queries to internal PostgreSQL database 9.5 which conforms to SQL standard ISO/IEC 9075:2011. The component is capable of handling additional binary types of records such as: txt, xml, html, xls and pdf.

On this page:

SQL Queries

The definitions of the database tables (.mql file extension) are in the /opt/masonsql/htdocs/data/ directory, subdivided into subfolders with the names of the database schemas.

MQL Files

When looking at the contents of .mql files its important to keep in mind that the <%method> block uses slightly unique syntax: The method's contents is, in turn, a component which is visible outside of current component and can be inherited via Mason's component inheritance mechanism. Thus the methods from the .mql files define additional layer in between HTML and the core dbms_library.comp component. Using the Mason methods is described in detail in The Mason Book, Chapter 5: Advanced Features.

Binding Data With Widgets

  • A Client browser uses the Javascript library /opt/masonsql/htdocs/lib/displaybinding.js for navigating the data from the MasonSQL database.
  • A Client browser uses the Javascript library /opt/masonsql/htdocs/lib/databinding.js for editing the data from the MasonSQL database.

Null values

The PostgreSQL database handles null values in the fields efficiently, without allocating memory space.
Null values are most useful in aggregate queries because they are not counted.

The MasonSQL framework handles null values considering the values returned by widget to null when the strings contains "" value (zero-length string).

Boolean fields follow the same rule with the value to true or null.

This topic if explored further in the SQL NULL chapter.

Reporting

You can find a complete documentation of both reporting engines here.

Legacy Reporting

The RP Designer is used for extracting reports from the internal PostgreSQL database.

The report files (.rep file extension) are in the /opt/masonsql/htdocs/data directory.
  • A .wine.rep file extensions are intended for Windows version of the RP Designer, running with WineHQ.
  • A .kylix.rep file extensions are intended for Linux version of the RP Designer.

See the public resources at http://reportman.sourceforge.net/ to find more information about the RP Designer.

Warning: Linux version is not compatible with UTF8 characters in PDF documents.

ODT Reporting

The ODT Reporting is a reporting interface integrated into the MasonSQL. The interface in combination with .odt template files, created with LibreOffice enables user to design new reports.
Topic revision: r13 - 22 Apr 2018, GuidoBrugnara
This site is powered by FoswikiCopyright (©) Leader.IT - Italy P.I. IT01434390223 Privacy policy & use of cookies