[sqlite] Can I define collation-aware SQL functions?

2015-05-16 Thread Zsbán Ambrus
On 5/15/15, Richard Hipp  wrote:
> No there is not.  The APIs used to implement those built-in functions
> are not exposed to the application-defined function interface.

Understood. Thank you for the reply.

-- Ambrus


[sqlite] Can I define collation-aware SQL functions?

2015-05-15 Thread Richard Hipp
On 5/15/15, Zsb?n Ambrus  wrote:
> Dear SQLite list,
>
> A few of the built-in SQL functions of SQLite has a result that
> depends on the collation sequence of the arguments, and compare text
> values using these collation functions.  These functions are "min" and
> "max" (both aggregate and scalar versions) and "nullif".
>
> Is there a way to define new SQL functions that behave in such a way?
>

No there is not.  The APIs used to implement those built-in functions
are not exposed to the application-defined function interface.  Which
is good, because they have changed once or twice for performance
reasons and had they been exposed, those changes would have caused
problems.
-- 
D. Richard Hipp
drh at sqlite.org