• 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 insert data from file excel into DB?

 
Greenhorn
Posts: 12
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi all,
Could you please tell me how insert data from Excel file to database.
Example: my excel file include members information (username,pwd,email,fullname). My DB have table member. And I want insert list members from excel to DB
 
Rancher
Posts: 13459
Android Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
"good luck",
It appears that you have changed your name from a valid display name to an invalid display name. Please change it back, accounts with invalid display names get deleted.
This is not a servlet question, I'm moving it to the JDBC forum.
Dave.
 
Bartender
Posts: 1844
Eclipse IDE Ruby Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Well, you could create an ODBC driver to your Excel file and read and write data that way (using the JDBC-ODBC Bridge). Also, depending on the database, there may already be conversion utilities available (Access and SQL Server have such utils (them being M$), but I think other DBs do as well...)
[ November 19, 2003: Message edited by: Joel McNary ]
 
Ranch Hand
Posts: 1879
MySQL Database Suse
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
If possible, from excel save the file as a tab delimited text file. Read the file in, parse the data columns ( use reg. expressions if possible ) then write each line of data to your database. I do have delimited file reader class (for JDK 1.4) that can make this easier if you decide to go that route.
Jamie
 
Ranch Hand
Posts: 63
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
You have framework to read Excell files on jakarta it is POI.
 
Ranch Hand
Posts: 925
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
export as csv, then import using sql-loader
 
reply
    Bookmark Topic Watch Topic
  • New Topic