GSOC ReportBuilder Weekly Update
Adam Seskunas
adamseskunas at gmail.com
Wed Jun 11 21:25:33 UTC 2025
Hello all,
As mentioned in my last update, I'm still working on integrating the
database data into a report document from within the C++ code in
https://opengrok.libreoffice.org/xref/core/reportdesign/source/filter/xml/xmlExport.cxx
When I left off, I was blocked getting the column data from the
ReportDefinition object without having to make a database query for every
instance of database data. After talking it over with my mentors, we came
up with a few different ideas to help with a solution. I looked into each
of these in turn, such as modifying the ReportDefinition to contain the
column information, and ultimately starting reading through some
documentation and the existing code to see how this problem is currently
solved.
While reading through some old documentation (2003!) on the Java
JFreeReport Class, I found that at one point the JFreeReport class used the
TableModel Class to hold the database results which then allowed access to
the data in individual columns. This lead to the code in
https://opengrok.libreoffice.org/xref/core/reportbuilder/java/org/libreoffice/report/SDBCReportData.java
The SDBCReportData class gets meta data from an XRowSet object that then
allows tabular access to the data from one database query, which is just
what I was looking for.
So currently I'm using a couple of the ideas in SDBCReportData to allow
tabular access to the database data in xmlExport. Eventually a full port of
SDBCReportData from Java to C++ will probably be necessary. Getting the
database data into a Report will allow further testing of xmlExport to
determine what other steps will need to be taken to implement ReportBuilder
in C++.
One other note, while reading the documentation of the JFreeReport Class
there are detailed explanations of the Grouping and Function capabilities
that it seems are currently available in the ReportBuilder. These will have
to be implemented in C++ and it remains to be seen how difficult and time
consuming this will be. After the database data has been successfully
implement I will begin to look into how these are implemented in the Java
code and what will need to be done for these capabilities to be implemented
in C++.
That's all for now
Cheers,
Adam
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/libreoffice/attachments/20250611/b85ee91e/attachment.htm>
More information about the LibreOffice
mailing list