• 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

how to fetch data from excel sheet and dump to Mysql database

 
Greenhorn
Posts: 13
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
how to fetch data from excel sheet and dump to Mysql database..

i had written code to fetch the data from the excel sheet using excel api (POI HSSF) given by Apache.

and i am able to display it on the console

but how to dump it to the database is the real issue...

Help guys help...


Thanks in advance...
 
Ranch Hand
Posts: 608
Firefox Browser Spring Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Connect to the database using JDBC and just use some insert queries to dump the data. Ummm...why is this a servlet problem?

P.S - There might be a better way to just import the data in Mysql..
 
Rancher
Posts: 43081
77
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Do you know how to use JDBC (the standard Java API for accessing databases)? If yes, what particular issue do you have with inserting the data? If not, start here: http://java.sun.com/docs/books/tutorial/jdbc/index.html
 
sandy indira
Greenhorn
Posts: 13
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
actually from a excel sheet the data is fetched from cells(i.e all the data is fetched from rows).. then how to dump the data in mysql database where we put data in columns..

i have nerver done this kind of stuff b4... so if anyone can suggest how the whole loop should be like..
i. how my "for loop" should be..in my case i am taking the username and password from the excel sheet and have to dump this in the
user name and password of the sql database..

any suggestions wil be greatly appreciated...
 
sandy indira
Greenhorn
Posts: 13
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
thank you guys 4 help..


i had some changes in it and now its working...
 
author
Posts: 5856
7
Android Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
"sandy the developer", please see your private messages for an important administrative matter.
 
Peter Johnson
author
Posts: 5856
7
Android Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

guys 4 help.


of stuff b4


Please use full words, not "text speak": http://faq.javaranch.com/java/UseRealWords
 
reply
    Bookmark Topic Watch Topic
  • New Topic