AW: SQL tuning?

Tiemo Hollmann TB toolbook at kestner.de
Fri Nov 21 05:04:14 CST 2008


Hello Ivan,
good to know, I will check it!
Thank you
Tiemo

> 
> The first thing comes to my mind is:
> 
> If you can make some assumption like: t1.f3 LIKE " & s3 " is most probably
> gets to fail
> you should put it on the first place in "where" clause (In case of
> fail on this statement there is no need to check other conditions).
> It is general "rule"
> 
> On the other hand, probably there is not the best db-design if you
> need such queries. There is too much of string comparison. Try to
> find better conditions to select records or redesign the db.
> 
> The second thing is:
> You can write own stored procedure which will build and execute the query
> "on the
> fly" depending on passed 4 values. I mean if second value is empty
> you omit "and t1.f2 LIKE " & s2 "" condition in the query and so on.
> 
> 
> --
> Best regards,
> Ivan Smahin
> Senior Software Engineer
> Paradigma Software, Inc
> Valentina - The Ultra-Fast Database
> http://www.valentina-db.com
> 
> _______________________________________________
> Valentina mailing list
> Valentina at lists.macserve.net
> http://lists.macserve.net/mailman/listinfo/valentina



More information about the Valentina mailing list