| Author |
Storing data rows in hashmap
|
rachana ravali
Ranch Hand
Joined: Jun 20, 2006
Posts: 32
|
|
Hi ,
i have a requirement where i have to put rows from database into hashmap as keys and values.
I have a doubt whether hashmap can support large data such as 2000 records or entries.
Can any one please clarify whether it is a good idea to have such as huge data in maps for avoiding network traffic with database.
Thanks in advance.
|
 |
Manish Singh
Ranch Hand
Joined: Jan 26, 2007
Posts: 160
|
|
|
If it reduces the DB calls then yes. And you need to look at whats the size of the entry. I mean you should be aware of the total memory taken by the hashmap
|
 |
Paul Clapham
Bartender
Joined: Oct 14, 2005
Posts: 16483
|
|
|
2000? That isn't "huge". It isn't even "large". Consider that your memory is measured in megabytes -- that's millions of bytes.
|
 |
rachana ravali
Ranch Hand
Joined: Jun 20, 2006
Posts: 32
|
|
thanks manish and paul ... thank you very much for replying..
|
 |
 |
|
|
subject: Storing data rows in hashmap
|
|
|