List:General Discussion« Previous MessageNext Message »
From:Jason Pyeron Date:August 1 2005 2:39pm
Subject:RE: query unexpectedly took too long.
View as plain text  
On Mon, 1 Aug 2005, Jay Blanchard wrote:

> CREATE TABLE bvolset (
>    id int(11) NOT NULL auto_increment,
>    bdate datetime default NULL,
>    level int(11) NOT NULL default '0',
>    PRIMARY KEY  (id),
>    UNIQUE KEY bdate (bdate),
>    KEY level (level)
> ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
> [/snip]
>
> Proper indexing will solve your problem. Index bdate and level, that
> should speed things up considerably.
>

do you mean as above:

PRIMARY KEY  (id),
UNIQUE KEY bdate (bdate),
KEY level (level)

or

index (bdate,level) ?



-- 
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
-                                                               -
- Jason Pyeron                      PD Inc. http://www.pdinc.us -
- Partner & Sr. Manager             7 West 24th Street #100     -
- +1 (443) 921-0381                 Baltimore, Maryland 21218   -
-                                                               -
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-

This message is for the designated recipient only and may contain 
privileged, proprietary, or otherwise private information. If you 
have received it in error, purge the message from your system and 
notify the sender immediately.  Any other use of the email by you 
is prohibited.
Thread
query unexpectedly took too long.jpyeron1 Aug
  • Re: query unexpectedly took too long.SGreen1 Aug
RE: query unexpectedly took too long.Jay Blanchard1 Aug
  • RE: query unexpectedly took too long.SGreen1 Aug
  • RE: query unexpectedly took too long.Jason Pyeron1 Aug
RE: query unexpectedly took too long.Jay Blanchard1 Aug