• Post Reply Bookmark Topic Watch Topic
  • New Topic

csv with jsp  RSS feed

 
Sunesh Kumar
Ranch Hand
Posts: 89
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Friends

I developed an application is gets the data from the csv file and stores the data in the database which i am succeeded .

Now i want to create another application by which i have to generate a CSV file based on the data in the database using JSP.

friends please share your ideas...

Waiting for your replies...
 
William Brogden
Author and all-around good cowpoke
Rancher
Posts: 13078
6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Now i want to create another application by which i have to generate a CSV file based on the data in the database using JSP.


What does JSP technology - designed for writing HTML pages - have to do with writing a text file in CSV format

It sounds to me like you should make a separate class that can do the query and write a CSV formatted character stream. You can test this outside the JSP/servlet environment.
Bill
 
Sunesh Kumar
Ranch Hand
Posts: 89
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi William

I cant get u cleary william sorry for that.

Can u give any idea to create csv file using the data in the table
by using JSP

bye...
 
Bear Bibeault
Author and ninkuma
Marshal
Posts: 65833
134
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
William is saying that JSP is not a good technology choice for this purpose.
 
Gerardo Tasistro
Ranch Hand
Posts: 362
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Make your application open a new window.
Call a servlet there
Have the servlet return the csv data.

Using a JSP is just overhead.
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!