This week's book giveaway is in the Clojure forum.
We're giving away four copies of Clojure in Action and have Amit Rathore and Francis Avila on-line!
See this thread for details.
Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

CSV File Manipulation

 
Azeem Mohammed
Greenhorn
Posts: 12
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

Can someone tell me how CSV files are manipulated in Java? And is there a way that new columns can be created in a CSV file with excel formulas using Java ?

Thanks,
Azeem
 
prem pillai
Ranch Hand
Posts: 87
Java Opera
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I think we are well aware that CSV file is a plain text file with comma separated values in it. So its just simple plain text; formatting facilities, formulas etc are not available. Spreadsheets like excel allows to view a CSV file in a tabular format. So what ever jazzy facilities you see in excel are not owned by CSV.

Now you know that CSV is a plain text , you know how to handle a plain text file with a comma delimited tokens (CSV file processing can be more complex depending on the type of data you have For example handling embedded commas , quotes etc makes it complex if your data demands for it).

Now if you dont want to create a CSV , but a spredsheet with jazzy features , then go for tools like Apache POI.
 
Ulf Dittmer
Rancher
Pie
Posts: 42966
73
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The http://www.coderanch.com/how-to/java/AccessingFileFormats page points to a number of libraries that can be used to manipulate CSV files, but I think they're mostly about reading and writing, not manipulating.
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic