Hi, El 18/10/10 07:14, HJ escribió:
> If I store them (as singles) compressed to a normal > file then I reach 10Mb and if i store them simply as a concat of texts > to a file then it results into a size of 20MB. I don't understand what do you mean. Compressing each row individually and written to a file end with 10mb, and the same text uncompressed ends with 20mb size ? > The other idea of Thomas, that half empty b trees might affect the > size cant be true since i created a table with an indexed INTEGER > field. Hence the large text field is only stored aside the indexed > field. and 42000 INT values dont result into a B tree of 40MB :-). You miss understand, talking about binary type overhead Thomas say that row insertion algorithm on a b-trees "try" to matain 50% of b-tree nodes free because performance reasons. > @Dario: The script idea doesnt help either (Its simply not a doable > task when users use embedded databases of the size of some gigs) I really dont understand the scenario of your use case. I say using SCRIP with and init script on connection URL like: jdbc:h2:file:~/sample;INIT=RUNSCRIPT FROM '~/create.sql'\\;RUNSCRIPT FROM '~/populate.sql' as a way to deploy a new data set to clients with minimal size. If your populated database have 10GB you can deploy it to clients as a 1.5GB script that populate your remote database on case of a new data set deploy, and I can't imagine other way to send such data volume in a more compact form. For a 10GB db ,your compressed text file would be about 2.8 Gb, right ? > I think that the only thing I can do now is to store the large field > from my db to a file and single compressed and storing the location to > the database > > Another and maybe a little dumb question is, how to activate the > lobsindatabase option. Is the a connection parameter System properties can be set with (http://www.h2database.com/javadoc/index.html): System properties can be set when starting the virtual machine: java -Dh2.lobInDatabase=true They can be set within the application, but this must be done before loading any classes of this database (before loading the JDBC driver): System.setProperty("lobInDatabase", "true") regards, Dario -- 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.
