I'm working on a spring boot application. I have got a database and I'm using JPA-hibernate to control that database. I need to get all those data into an excel file but there is a problem. The user can create new columns while the program is running. So I don't know how can I overcome that problem. I've found Apache POI and I don't think it's enough. In Apache POI I need to create column names by myself but I don't know new column names and the number of columns in my program. So what should I do?
Asked
Active
Viewed 273 times
0
-
Instead of using Spring Boot to achieve this, you can add a trigger to the database that'll create a CSV file on every insert. If you're using MySQL, check out https://stackoverflow.com/questions/44828475/mysql-automatically-export-to-new-csv-files-on-trigger – Keshavram Kuduwa Mar 09 '21 at 14:39
-
@KeshavramKuduwa actually, it's a web project and we're doing that with spring. The question is related to the database to excel – hburak_06 Mar 09 '21 at 16:55
-
I understand that, my question is, why create a web project when this can be achieved at database level? – Keshavram Kuduwa Mar 09 '21 at 17:49
-
One of my friends wanted that system. He wants to manage his workers online. So I need a web application. Also, he wants to get some tables to excel files. @KeshavramKuduwa – hburak_06 Mar 09 '21 at 20:45