This week's book giveaway is in the OCAJP 8 forum.
We're giving away four copies of OCA Java SE 8 Programmer I Study Guide and have Edward Finegan & Robert Liguori on-line!
See this thread for details.
The moose likes Servlets and the fly likes Reading the excel file Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of OCA Java SE 8 Programmer I Study Guide this week in the OCAJP 8 forum!
JavaRanch » Java Forums » Java » Servlets
Bookmark "Reading the excel file" Watch "Reading the excel file" New topic
Author

Reading the excel file

sunitha reghu
Ranch Hand

Joined: Dec 12, 2002
Posts: 937
I am using hssf to read an excel which users uploading to a servlet.
The problem is that it can not read the SSN . So i made ssn as text. But i already have name as text. I am geteting ssn and anem as text. My que how to take ssn out frm that.
I pasting the portion of the code.


The name of the employee is coming up with ssn and the name.
Can anyone help me??
[ November 17, 2003: Message edited by: sunitha raghu ]
Jeanne Boyarsky
author & internet detective
Marshal

Joined: May 26, 2003
Posts: 32633
    
215

Are you saying that SSN and name are in the same cell? If so, you would get the whole cell as text and parse it.


[OCA 8 book] [Blog] [JavaRanch FAQ] [How To Ask Questions The Smart Way] [Book Promos]
Other Certs: SCEA Part 1, Part 2 & 3, Core Spring 3, TOGAF part 1 and part 2
sunitha reghu
Ranch Hand

Joined: Dec 12, 2002
Posts: 937
No ssn and name are in diff cell.
so both are getting are string values.
i solved that using regular expression.
but if some enters ssn with hyphen then it will be problem
then i will get that in name field. so have to find some way for that.
Originally posted by Jeanne Boyarsky:
Are you saying that SSN and name are in the same cell? If so, you would get the whole cell as text and parse it.
 
Don't get me started about those stupid light bulbs.
 
subject: Reading the excel file
 
It's not a secret anymore!