Re: Good Informix bug found
Posted in 1996
I think the optimizer in 7.12 is handling dates differently than prior
Informix versions.
On 7.10.UC3X1 when I run:
select count(*) from table where date_column >= '01/01/96'
the filter in the set explain output is:
...date_column >= 01/01/1996
and
select count(*) from table where date_column >= DATE('01/01/96')
the filter is:
...date_column >= DATE('01/01/96')
On 7.12.UC1P2 when I run the first query the filter is:
...date_column >= '01/01/96'
and the second query the filter is:
...date column >= 01/01/1996
The first query runs 3 to 4 times longer on 7.12 than 7.10. The second
query runs faster in 7.12.
It seems that the optimizer converted date constants to integers in 7.10
and does not convert in 7.12. Also the DATE function did not convert in
7.10 but does in 7.12.
Is this a feature or a bug? When do I tell the programmers to start
changing their code? :) They're not going to be happy!
Does anyone know if this is fixed in 7.13?
Send Help.
Steve Berg - spb@masada.nb.com