On 12-7-2012 22:14, Leyne, Sean wrote: > Bad example, I should have said that: > > SELECT ... FROM ... WHERE ColumnA = COS( ColumnB) > > Doesn't use an index when it should be able to, just as the engine is able to > use an index for this query > > SELECT ... FROM ... WHERE ColumnA = ColumnB
It is still a bad example, a full table scan is still required to calculate COS(ColumnB) and then compare it against ColumnA, no amount of indices is going to help against that. I am not really sure if Firebird will actually able to use indices for evaluating ColumnA = ColumnB either, but I assume that will only work if both columns have an index. Mark -- Mark Rotteveel ------------------------------------------------------------------------------ Live Security Virtual Conference Exclusive live event will cover all the ways today's security and threat landscape has changed and how IT managers can respond. Discussions will include endpoint security, mobile security and the latest in malware threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ Firebird-Devel mailing list, web interface at https://lists.sourceforge.net/lists/listinfo/firebird-devel