Re: Query performance
Posted in 1997
Alain Martin wrote: > > Hi > > I have a simple query that takes about 5 minutes to display is result. The > problem is the order by in the query. It use a temporary file. Whitout it, > it`s a lightning. Did you 'update statistics' for the table? The optimizer must have figured that there were few enough values for the field in the index that was used that the 'order by' would be trivial. And what is the reason for this filter: rsp.a0631_rol_no >= '' ordinarily shouldn't it be: rsp.a0631_rol_no is not null except that the field has a not null constraint on it anyway which makes this filter pointless. Oh, and I couldn't see the entire attached file. But after I looked at the half I did see, every news message I looked at after that was scrambled. That's the last time I ever look at ANY attached file. Cheers, Douglas Wilson