Exporting Reports Enhancements
Users can now export reports as CSV files. Clicking the Save as CSV option on the Report page initiates the process. Once completed, the user will be notified that they can download the CSV file under the Download Report tab on the Report age.
The file generation process has three states: PROCESSING, COMPLETED, and FAILED. The status for each report file generation process can be tracked on the Download Report tab.
The user is restricted against generating reports beyond the storage limit to avoid running out of space on the server. The report size limit can be changed by setting storage limit for ReportCSV table. Default configured limit is 4GB.
- Total number of saved reports: MAX_ROWS = 100
- Average report size: AVG_ROW_LENGTH = 42949672 (42 MB)
- Total maximum saved report data: MAX_DATA_LENGTH = 100*42949672 = 4GB
If a user generates a report file and the table limit is reached, then the file generation process will fail and a FAILED status is logged on DB and displayed in the Prime Home UI. The error log is updated with a message indicating why the report save failed.
This new feature stores potentially very large file contents to the MySQL DB, and therefore the maximum allowed packet size for MySQL connection should be increased. MySQL has a default allowed packet size of 1MB; it must be changed to 256MB (Note that this will also be the maximum report size since any report larger than this will terminate the DB connection during report generation).
Perform the following procedure on the My SQL database server to set the maximum allowed packet size for MySQL connection.
Step 1 Log in to the database server
sudo edit /etc/my.cnf
Step 2 Add the line: max_allowed_packet=256M under the [mysqld] section.
Step 3 Restart the mysql service & Prime Home application.