On 3/12/20, Doug wrote:
>
> Something triggered me when I looked at the generated code: you use the
> contents of register 2 for the constant value each time through the loop.
> What if the select looks like this, with more than one function call in the
> coalesce? Do you handle it properly?
>
>
(a, abs(0), abs(1), abs(2)) FROM t1;
Just curious...
Doug
> -Original Message-
> From: sqlite-users
> On Behalf Of Richard Hipp
> Sent: Thursday, March 12, 2020 7:41 AM
> To: SQLite mailing list
> Subject: Re: [sqlite] [EXTERNAL] Re: COALESCE() does not short-
> circui
On 3/12/20, Doug wrote:
> Richard, what does the explain look like with your code change, please.
Test case:
CREATE TABLE t1(a);
explain SELECT coalesce(a, abs(-9223372036854775808)) FROM t1;
Before the change:
addr opcode p1p2p3p4 p5 comment
Function0 1 5 4 abs(1) 01
> r[4]=func(r[5])
> > 13Goto 0 1 000
> >
> > -Ursprüngliche Nachricht-
> > Von: sqlite-users [mailto:sqlite-users-
> boun...@mailinglists.sqlite.org] Im
> > Auftrag
ailto:sqlite-users-boun...@mailinglists.sqlite.org] Im
> Auftrag von Jay Kreibich
> Gesendet: Mittwoch, 11. März 2020 20:53
> An: SQLite mailing list
> Cc: 38866424f8f6fc429174ff1ab2355...@mail.dessus.com
> Betreff: [EXTERNAL] Re: [sqlite] COALESCE() does not short-circuit
> somet
icht-
Von: sqlite-users [mailto:sqlite-users-boun...@mailinglists.sqlite.org] Im
Auftrag von Jay Kreibich
Gesendet: Mittwoch, 11. März 2020 20:53
An: SQLite mailing list
Cc: 38866424f8f6fc429174ff1ab2355...@mail.dessus.com
Betreff: [EXTERNAL] Re: [sqlite] COALESCE() does not short-circuit sometim
> I have a patch to fix the problem on a branch
> (https://www.sqlite.org/src/timeline?r=do-not-factor-functions) which
> you can experiment with. More changes and analysis are needed prior to
> landing on trunk. I cannot guarantee that such a landing will in fact
> occur, though it seems more
I recently tried using Coalesce() to check existence of a column name.
SELECT DISTINCT COALESCE((SELECT 'AColumnThatDoesNotExist' FROM TD), -999)
FROM TD;
But, the SQL error code dominates? "no such column: AColumnThatDoesNotExist"
Had to resort to:
SELECT name FROM pragma_table_info('TD') WHERE
On 3/11/20, Hick Gunter wrote:
> While ORACLE does state that COALESCE will short circuit,
A similar problem was reported on a ticket here:
https://www.sqlite.org/src/tktview?name=3c9eadd2a6 (The problem
reported on that ticket might not seem to be the same at first glance,
but deep down they
te-users-boun...@mailinglists.sqlite.org] Im
Auftrag von Justin Ng
Gesendet: Mittwoch, 11. März 2020 16:24
An: sqlite-users@mailinglists.sqlite.org
Cc:
vi1p195mb06545f03a24d50dd2785ac2bde...@vi1p195mb0654.eurp195.prod.outlook.com
Betreff: [EXTERNAL] Re: [sqlite] COALESCE() does not short-circuit som
to the program
-Ursprüngliche Nachricht-
Von: sqlite-users [mailto:sqlite-users-boun...@mailinglists.sqlite.org] Im
Auftrag von Dominique Devienne
Gesendet: Mittwoch, 11. März 2020 13:19
An: SQLite mailing list
Betreff: [EXTERNAL] Re: [sqlite] COALESCE() does not short-circuit sometimes
On Wed
11 matches
Mail list logo