• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • Liutauras Vilda
  • Jeanne Boyarsky
  • paul wheaton
Sheriffs:
  • Ron McLeod
  • Devaka Cooray
  • Henry Wong
Saloon Keepers:
  • Tim Holloway
  • Stephan van Hulst
  • Carey Brown
  • Tim Moores
  • Mikalai Zaikin
Bartenders:
  • Frits Walraven

Reading Data from Excel Sheets

 
Ranch Hand
Posts: 52
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi!
I have an Excel Sheet that contains different Columns such as

SCRIPT and RESULT

I have to read data from SCRIPT column and write some data in RESULT column.
This Excel Sheet contains 10 rows.

How do I can read data (from specific column) from Excel Sheet and then write in the (specific column) Excel Sheet.
 
Bartender
Posts: 10336
Hibernate Eclipse IDE Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
This seems to be an operation contained in Excel - in which case why not do it with Excel formulae or VBA?

If you need to handle it through Java, probably the easiest route is with Jakarta POI.
 
P Jain
Ranch Hand
Posts: 52
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi!
Thanks for youe reply
But can I access excel file (especially csv) by using simple java.
Or it is necessary to use JDBC for this.
Because normally when we have to access text file we don't use JDBC.
 
Sheriff
Posts: 13411
Firefox Browser VI Editor Redhat
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
There is no native support for Excel built into Java but you can certainly parse a csv file.

Look either at Java's regexp support (1.4 or higher) or the java.util.StringTokenizer for older versions.

The java.io.BufferedReader(java.io.FileReader)
has a readLine method.
 
straws are for suckers. tiny ads are for attractive people.
Gift giving made easy with the permaculture playing cards
https://coderanch.com/t/777758/Gift-giving-easy-permaculture-playing
reply
    Bookmark Topic Watch Topic
  • New Topic