File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Beginning Java and the fly likes HashMap values Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Make it so: Java DB Connections & Transactions this week in the JDBC forum!
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "HashMap values " Watch "HashMap values " New topic

HashMap values

kri shan
Ranch Hand

Joined: Apr 08, 2004
Posts: 1407
First i want to add my values with key to the HashMap. Finally i add these HashMap values to the db.(db insertion)
How can i do that?
Paul Sturrock

Joined: Apr 14, 2004
Posts: 10336

You add values to a HashMap with the put(Object, Object) method, as you can see if you read the JavaDocs for HashMap.

You can add data to a database using JDBC. And there is a tutorial for this at Sun.

JavaRanch FAQ HowToAskQuestionsOnJavaRanch
I agree. Here's the link:
subject: HashMap values
It's not a secret anymore!