List:General Discussion« Previous MessageNext Message »
From:Dan Nelson Date:December 5 2002 10:03pm
Subject:Re: Questions Compressed Tables & Indexs
View as plain text  
In the last episode (Dec 05), Michael She said:
> I'm planning to run a remote DB across the internet for a web
> application and I would like to minimize retrival times and
> bandwidth.
> I have a couple of questions about MyISAM compressed Tables:
> 1. Is it slower to retrieve from a compressed table, or actually
> faster since data is packed?

Slightly faster, but the difference is nothing compared to disk seek
times, so you'll never notice it.  Also note that compressed tables are

> 2. Is there an increase in CPU overhead? Is it significant?


> 3. Is the data sent to the client compressed or decompressed?

Protocol compression is separate from Table compression.  To enable
protocol compression, set the CLIENT_COMPRESS flag when connecting to
the server, or add the "compress" keyword to the [client] block of your
my.cnf file.
> As for indicies is it better to create a single index per column, or
> an index for a set of columns. For example, if I go: SELECT * FROM
> SOMETABLE WHERE A = X and B = Y. Is it better to create a X AND Y
> index, or two separate indicies?

For that partucilar query, you need a single index over both columns,
since Mysql will only use one index per table.

	Dan Nelson
Re: Questions Compressed Tables & IndexsMichael She5 Dec
  • Re: Questions Compressed Tables & IndexsDan Nelson5 Dec
    • Re: Questions Compressed Tables & IndexsMichael T. Babcock6 Dec
  • Re: Questions Compressed Tables & IndexsSteve Yates6 Dec