--- Jeff Beer <[EMAIL PROTECTED]> wrote:
> Is there any benefit to indexing a "tinyint" field
> that is used as a boolean
> (either 1 or 0)?  I have four fields that work this
> way and I use them
> heavily in queries for reporting.  They are used in
> aggregate functions
> (count and sum) as well as in the where clauses for
> various queries.

Indexing isn't helpful unless you have a large number
of distinct values (relative to total database
entries) and may even be harmful. In the case of a
boolean field, it's a definite no no.


=====
I-Lin Kuo
Macromedia CF5 Advanced Developer
Sun Certified Java 2 Programmer

__________________________________________________
Do You Yahoo!?
Yahoo! Sports - Coverage of the 2002 Olympic Games
______________________________________________________________________
Dedicated Windows 2000 Server
  PIII 800 / 256 MB RAM / 40 GB HD / 20 GB MO/XFER
  Instant Activation · $99/Month · Free Setup
  http://www.pennyhost.com/redirect.cfm?adcode=coldfusiona
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists

Reply via email to