On 2015-01-06 12:50 PM, Steve McLeod wrote:
When our users update to the latest version of our desktop software that uses 
H2, we need to add several columns to a
table with many columns that may have millions of rows. Some people have been 
getting an OutOfMemoryException during
this process.


That is rather odd, since H2 should be creating a temporary table if the 
result-set gets too big.
I do this all the time, and I don't have OOM problems. It sure can take a long time though, which I have some suggestions for, but first lets sort out this bug.

What does your H2 URL look like, and what does your ALTER TABLE statement look 
like?

I've analysed this problem, and checked the H2 source code for ALTER TABLE ADD. 
It seems that the high RAM usage is
occurring during the data copying step.


Can you be more specific - what data-structure is using up memory and what 
section of H2 code?

--
You received this message because you are subscribed to the Google Groups "H2 
Database" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to h2-database+unsubscr...@googlegroups.com.
To post to this group, send email to h2-database@googlegroups.com.
Visit this group at http://groups.google.com/group/h2-database.
For more options, visit https://groups.google.com/d/optout.

Reply via email to