hi everyone!
i just want to share a technique i'm using to compress data stored on
TEXT fields in a database. basically it uses the zlib extension of PHP.
you have a function called gzcompress() to return a compressed version of an input string and a function called gzuncompress() to decompress it.
for instance, i needed to serialize a massive array and store it in
a database field. since there is much redundancy in the serialized form
(string), it's useful to compress it. for instance, i had 17KB worth of
data compress to just 7.8KB.
of course the disadvantage to compressing data is that you can't
search it within an SQL query because you'll have to decompress it
first. but if you need to store large amounts of information somewhere
and that info can be shrinked via compression, it's a good tool to use
http://devpinoy.org/blogs/cruizer
Naglalayong buksan at palayain ang kamalayan ng Pinoy .NET developer