Q
Problem solve Get help with specific problems with your technologies, process and projects.

Sending queried data from the Web to a CSV or Excel file

I have 12 tables that I need to query via JSP... no problem. Then I display a view of data in a JSP page, and I would like to send/save the data to an Excel or CSV file format. I've seen pages where you ask users to download a CSV file and then they can open it in Excel, but the scripts are server-side, and I can't seem to find any documentaion on exports other than .dmp files with Oracle. Any ideas, or resources you can recommend? The data needs to eventually end up in an Excel template that allows user to sort, and add data. Using a total Web solution is planned for the future, but development time is short and a quick solution is needed. I don't have to save any of the data back to Oracle from Excel in this first attempt, only send the queried data from the Web to a CSV format or an Excel file/template... hope you can help.

If I understand you correctly, you are trying to write a JSP application which will let you save the output from a database query to the user's hard drive in CSV format. The easiest way to do this is to create a JSP page which displays the information in comma-delimitted form! Then, the user just has to choose File->Save As from their browser window and save the HTML page as TEXT format.

If you want this to be automated, then you are probably looking at creating a Java applet which takes the output and puts it in a file on their hard drive.

For More Information


Dig Deeper on Oracle database design and architecture

Have a question for an expert?

Please add a title for your question

Get answers from a TechTarget expert on whatever's puzzling you.

You will be able to add details on the next page.

Start the conversation

Send me notifications when other members comment.

Please create a username to comment.

-ADS BY GOOGLE

SearchDataManagement

SearchBusinessAnalytics

SearchSAP

SearchSQLServer

TheServerSide.com

SearchDataCenter

SearchContentManagement

SearchHRSoftware

Close