• 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
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

using servlets here??

 
Ranch Hand
Posts: 61
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,
i just wanted to know if the following is possible using Servlets.
i have two text files containing some data about the states in USA
ie say data file1 (area.txt) has data in the format: name of the state
followed by a tab and then the data value ie
New York 12000
New jersey 15000
........
and data file2 (den.txt) has New York 100
New Jersey 200
..............

now i extract the values "12000,15000 etc" from file 1 and
"100,200 etc" from file 2 and do a calculation like dividing "12000" with
"100","15000" by "200" etc. i have finished this part.
now is it possible to use servlet/JSP to map the results into a new
file. the new file should be as follows ie the name of the state with
the corresponding result value)
New York 120
New jersey 150
.......
ie the results obtained from the above calculations are to be mapped
onto their respective state names?
i need ur guidance in proceeding with the above functionality.
thanks in advance
 
Ranch Hand
Posts: 140
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Yes it is possible. Give or take some restrictions, a servlet behaves pretty much like an ordinary java class. All you should be asking is if Servlets are the right choice of technology to use - in this case they would be you need to provide this functionality remotely through a web client.
 
What are you doing? You are supposed to be reading this tiny ad!
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic