Re: Query Planner GROUP BY and HAVING clauses optimization ?

Simon Slavin <[email protected]>
Newsgroups gmane.comp.db.sqlite.general
Message-ID <[email protected]>
On 14 Jan 2020, at 4:14pm, Jean-Baptiste Gardette <[email protected]> wrote:

> The reason i asked this is that i have a query in wich one condition filtering the recordset involves
> an UDF and this UDF needs to be processed after all table filters have been applied

You cannot guarantee this.  And even if you find a solution that works now, the optimizer in a future version of SQLite might work differently.

Would it be possible to phrase your SELECT as a SELECT with a sub-SELECT ?  Have the sub-SELECT figure out which rows you want in which order, then use a SELECT to apply your UDF to them ?  It is guaranteed that the sub-SELECT is processed before the SELECT.
_______________________________________________
sqlite-users mailing list
[email protected]
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.