Okay, I've got a crude finding on one of my questions.

I had been storing an array of objects as text in a text field. Following
Cannon's suggestion on a nearby thread, I wrapped the array in an object
and stored that instead. Much messing around with 'corrupt' data files
later (see below), I was able to compare the size of two export files. One
with the data stored in a text field and one with the data stored as an
object. For those wondering:

* The text field based export was done when the object field for that data
didn't exist.
* The text field contained 'compact' (cough-cough) JSON rather than
pretty-printed.
* The object field version of the export was done only after the text field
had been converted, deleted, and compacted out of the 4DB and 4DD.

So, with text, my export was 24.66GB and as text it was 12.35GB, nearly 50%
smaller. Is that ratio reliable? No. I don't even know if my finding is
reproducible. But it makes sense that if the version of 4D I'm using (16.1)
has a binary format underneath the hood (which we seem to have no direct
access to), that it should be smaller than when exploded out to a chatty
JSON format.

I'd love to hear what others discover, if anything. Use my findings as
vague and not particularly reliable...it was just one test.

About the corruption. It was taking 8 hours to generate the data (due to
what I like to call "those darn 4D bugs" and other people call "David's
stupid mistakes"), so I wanted to convert the test data I already had. No
problem, create a text field, parse/wrap/save the data into the object
field. And then, delete the field and compact. Bit it wouldn't. Would not.
"Orphan blobs" in the data file. Repair fixed that and let me compact,
happily.
**********************************************************************
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**********************************************************************

Reply via email to