For example: If you want to insert 80 lacs ( I do not get what lacs is ), used some buffer strategy. In case, put you 10 lacs in a List, save, then clear the list ( list.clear() ) to put next 10 lacs. Do it repeatedly until 80 lacs.
I would expect 80 crore to overwhelm your memory, but not 80 lakh. Have you got some sort of recursion which doesn't terminate? [ April 25, 2008: Message edited by: Campbell Ritchie ]
Joined: Oct 13, 2005
Actually, how long is each line? 80 lakh * 100 Bytes is about 800MB so even 80 lakh might overwhelm your resources. What sort of table are you inserting into? A database? Are you using anything which maintains the lines in memory after you have inserted them? If you are inserting into a database, is there any delay in the database? Can you put a tiny delay between successive lines? Can you split the process so as to insert 1 line at a time?
And lakh (also spelt lac) = 100000
subject: Exception in thread "main" java.lang.OutOfMemoryError