I see.
So if I create a LOCAL TEMPORARY table it is persisted (possibly) to disk if I 
don't define NOT PERSISTENT?
Only the indexes are kept in memory without unless CACHED is used.

So to sum it up:
CREATE CACHED TEMP TABLE -> both rows and indexes are streamed to disk
CREATE [MEMORY] TEMP TABLE -> rows are streamed to disk and indexes are kept in 
memory
CREATE [MEMORY] TEMP TABLE ... NOT PERSISTENT -> both rows and indexes are kept 
in memory
CREATE CACHED TEMP TABLE ... NOT PERSISTENT -> ?!?


Also reading the docs carefully it says:"The default for temporary tables is 
global"
Which means that TEMP = GLOBAL TEMPORARY, right?

- rami

On 04/25/2011 10:07 AM, Sergi Vladykin wrote:
Hi,

NOT PERSISTENT table holds all the data in memory, its faster but you
can run out of memory.

regards,
Sergi


--
You received this message because you are subscribed to the Google Groups "H2 
Database" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/h2-database?hl=en.

Reply via email to