Jonah H. Harris wrote: > On Oct 08, 2006 07:05 PM, Josh Berkus <josh@xxxxxxxxxxxx> wrote: > > Hints are used because the DBA thinks that they are smarter than > > the optimizer; 99% of the time, they are wrong. > > That's a figure which I'm 100% sure cannot be backed up by fact. > > > Just try manually optimizing a complex query, you'll see -- with three > > join types, several scan types, aggregates, bitmaps, [blah blah blah] > > it's significantly more than a human can figure out accurately. > > Let me get this right... the optimizer is written by humans who know and > can calculate the proper query plan and generate code to do the same; > yet humans aren't smart enough to optimize the queries themselves? A bit > of circular reasoning here? I can do 100! on my computer, but can't do it in my head. -- Bruce Momjian bruce@xxxxxxxxxx EnterpriseDB http://www.enterprisedb.com + If your life is a hard drive, Christ can be your backup. +