Bug 168734 - Implement ReportBuilder in C++
Summary: Implement ReportBuilder in C++
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Base (show other bugs)
Version:
(earliest affected)
unspecified
Hardware: All All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: Base-Without-Java
  Show dependency treegraph
 
Reported: 2025-10-07 22:00 UTC by Adam664
Modified: 2025-10-09 07:06 UTC (History)
4 users (show)

See Also:
Crash report or crash signature:


Attachments
Example Document (86.46 KB, application/vnd.oasis.opendocument.database)
2025-10-07 22:05 UTC, Adam664
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Adam664 2025-10-07 22:00:05 UTC
Description:
Summary of work done, and work to be done to Implement ReportBuilder in C++. This project was started as a GSOC project in 2025. 

The Final Report for the project can be found here: 
https://gist.github.com/a-seskunas/2fd901534962b6ac728c6aee68a8b5c7



Steps to Reproduce:
1.Open the attached example document
2.Open a Report


Actual Results:
Base uses the Pentaho Report Engine to process the Report.

Expected Results:
The goal of the project is to implement the functionality provided by Pentaho in C++ so that Pentaho can be removed.


Reproducible: Always


User Profile Reset: No

Additional Info:
The Pentaho Report Engine is written in Java and causes packaging issues. In addition, the version of Pentaho currently used is very old and cannot be upgraded due to licensing issues.
Comment 1 Adam664 2025-10-07 22:05:35 UTC
Created attachment 203183 [details]
Example Document

There are multiple Reports in the example document that can be used to test the features that have been implemented in C++ with the commits built from the Implement Report Builder in C++ GSOC project. 

See 

https://gist.github.com/a-seskunas/2fd901534962b6ac728c6aee68a8b5c7

For a list of the commits.
Comment 2 Robert Großkopf 2025-10-08 06:27:51 UTC
Will be a good idea to change the code to C++. So I set this one to NEW.
Comment 3 Julien Nabet 2025-10-08 06:42:11 UTC
I know the work isn't over but it seems already a great job you did!

Lionel: put you in cc just in case you may want to comment. Don't hesitate to uncc if no time/not feel like, etc.
Comment 4 Adam664 2025-10-08 22:31:28 UTC
Follow up to Comment 1. 

With the commits from the project built, you can run ReportBuilder in C++ by setting the environment variable SAL_ENABLE_PENTAHO_FREE_REPORTBUILDER to 1 i.e.

SAL_ENABLE_PENTAHO_FREE_REPORTBUILDER=1 instdir/program/soffice

Then open the attached document and you can open one of the saved reports to test its output.

Below I will list the features of ReportBuilder that have been implemented in C++ and a saved report that demonstrates this. 

Labels -            BasicFields
TextBox-Text        BasicFields
TextBox-Field       BasicFields
TextBox-Formula     FormulaFieldInput
Sorting             GroupOnDogAge       
Group Header/Footer TwoGroups
GroupOn             GroupOn*
GroupInterval       GroupOnNamePrefix1
Font Type/Size      MultiPageAndSeveralFonts
Font Color          MUltiPageAndSeveralFonts
Background Color    ColoredGroupHeaders

For a detailed list of what has been implemented and what remains to be implemented in C++ see

https://gist.github.com/a-seskunas/2fd901534962b6ac728c6aee68a8b5c7#list-of-features-and-their-implementation-state

The list above is to serve as a reference for the reference document, there are features that have been implemented in C++ that don't have Reports to demonstration. 

A short term goal is to write unit tests that compare the output of the current Reportbuilder with the output of the C++ version using these or similar test documents.