List:General Discussion« Previous MessageNext Message »
From:Sebastian Mendel Date:April 23 2008 6:14am
Subject:Re: Weird result on max compared to order by
View as plain text  
jmacaranas@stripped schrieb:
> Hi,
> 
>   I did a select on a primary key.. 
>     Select max(account_id) from mytable;
>            -- it gave me a value X
> 
>   I did a select with order by
>     Select account_id from mytable order by account_id desc limit 3
>            -- it gave me a value of Y ( Y is the right value )
> 
> 
>   I was wondering why it didn't gave me the same value and after some
> time doing a select max gave me the right value "Y"

seems your index was corrupted

-- 
Sebastian Mendel
Thread
Weird result on max compared to order byjmacaranas22 Apr
  • Re: Weird result on max compared to order bySebastian Mendel23 Apr