List:General Discussion« Previous MessageNext Message »
From:Paul DuBois Date:July 15 1999 1:23am
Subject:Re: error with "order clause" without "where clause"
View as plain text  
At 2:30 PM +0200 7/14/99, Benjamin Pflugmann wrote:
>Hi.
>
>Sounds as if table/index got corrupted. Check it with isamchk and see
>if you find anything annormal.
>
>Bye,
>
>        Benjamin.
>
>On Tue, Jul 13, 1999 at 05:35:48PM +0200,
>philippe.jouguet@stripped wrote:
>[...]
>> select * from t_titre_sup order by tit_code
>> 465 rows in set (0.08 sec)
>>
>> select count(*) from t_titre_sup
>> +----------+
>> | count(*) |
>> +----------+
>> |      447 |
>> +----------+
>> 1 row in set (0.00 sec)
>>
>> There is a diffence about numbers of rows.
>> This is why some records are count two or three times and not order also.
>>
>> >Fix:
>> I add a "true where clause" with same data from the "order clause".
>> select * from t_titre_sup where tit_code > -1 order by tit_code
>> 447 rows in set (0.10 sec)


COUNT() counts only non-NULL values - could that be the problem?

--
Paul DuBois, paul@stripped
Northern League Chronicles: http://www.snake.net/nl/
Thread
error with "order clause" without "where clause"philippe jouguet13 Jul
  • Re: error with "order clause" without "where clause"Benjamin Pflugmann14 Jul
    • Re: error with "order clause" without "where clause"Paul DuBois15 Jul
    • Re: error with "order clause" without "where clause"philippe jouguet15 Jul