e first row per group.
Thanks again,
Eliedaat
-Original Message-
From: Ed Pasma [mailto:[EMAIL PROTECTED]
Sent: Monday, May 07, 2007 10:28 PM
To: Adler, Eliedaat
Cc: sqlite-users@sqlite.org
Subject: RE: [sqlite] Help wiith SQL - first row of each group
This solution may is tricky
On Mon, May 07, 2007 at 19:20:49 +0400, Tomash Brechko wrote:
> But with SQLite 3.x there is only one user data pointer per user
> defined aggregate function, so no parallel aggregate execution is
> possible.
Ah, I was too fast again :/. GROUP BY is really two-pass, but my
understanding why it
On Mon, May 07, 2007 at 18:10:29 +0400, Tomash Brechko wrote:
> The solution with two table scans might be
>
> SELECT * FROM RESULT_TABLE a
> WHERE P = (SELECT MIN(P) FROM RESULT_TABLE b WHERE b.G = a.G);
>
> You may also try to play with indexes G, P.
>
> It seems to be impossible to do
that "scans" TEST only once?
-Original Message-
From: Maulkye [mailto:[EMAIL PROTECTED]
Sent: Monday, May 07, 2007 4:35 PM
To: sqlite-users@sqlite.org
Subject: Re: [sqlite] Help wiith SQL - first row of each group
How about something like this:
create table test
(
G
On Mon, May 07, 2007 at 15:38:22 +0300, Adler, Eliedaat wrote:
> I need to define a query that returns only the "first' row in each group
> - i.e. the row with the lowest display priority:
>
> - most preferably a query that doesn't require selecting RESULT_TABLE
> more than once.
The solution
=pri.Grp and grp.Pri=pri.Pri
Grp Val Pri
---
AX1
BZ2
CY6
- Original Message
From: "Adler, Eliedaat" <[EMAIL PROTECTED]>
To: sqlite-users@sqlite.org
Sent: Monday, May 7, 2007 8:38:22 AM
Subject: [sqlite] Help wiith SQL - first r
Hi guys,
I have a complex query result set RESULT_TABLE that returns:
GVP
___
AX1
AX2
BY4
BZ2
BX8
CY6
CZ8
CX9
CY11
G
7 matches
Mail list logo