On 6/26/2012 4:02 PM, Pavel Ivanov wrote:
On Tue, Jun 26, 2012 at 3:02 PM, Igor Tandetnik wrote:
On 6/26/2012 1:19 PM, Peter Haworth wrote:
I still have the issue that, in order to be selected, the rows in the
groups containing two entries must have a different value in a specific
column.
On Tue, Jun 26, 2012 at 3:02 PM, Igor Tandetnik wrote:
> On 6/26/2012 1:19 PM, Peter Haworth wrote:
>>
>> I still have the issue that, in order to be selected, the rows in the
>> groups containing two entries must have a different value in a specific
>> column.
>
>
> I'm not quite sure I understa
On 6/26/2012 1:19 PM, Peter Haworth wrote:
I still have the issue that, in order to be selected, the rows in the
groups containing two entries must have a different value in a specific
column.
I'm not quite sure I understand the condition, but perhaps you are
looking for something like this:
http://www.lcsql.com>
>
>
>
> On Sat, Jun 23, 2012 at 9:00 AM, wrote:
>
>> Message: 5
>> Date: Fri, 22 Jun 2012 19:17:39 -0400
>> From: Pavel Ivanov
>> To: General Discussion of SQLite Database
>> Subject: Re: [sqlite] Selecting from a GROUP Sele
vanov
> To: General Discussion of SQLite Database
> Subject: Re: [sqlite] Selecting from a GROUP Select
> Message-ID:
> >
> Content-Type: text/plain; charset=ISO-8859-1
>
> I guess you need something like
>
> SELECT * from TableA
> WHERE z in (
> SELECT z F
I guess you need something like
SELECT * from TableA
WHERE z in (
SELECT z FROM TableA GROUP BY z HAVING count(*)=2
);
Pavel
On Fri, Jun 22, 2012 at 6:43 PM, Peter Haworth wrote:
> I have a situation where I need to select entries based on the count of the
> number of entries in a GROUP = 2,
I have a situation where I need to select entries based on the count of the
number of entries in a GROUP = 2, and also that the value of a specific
column must be different for each row in the group. I then need to select
all the individual rows from the qualifying groups.
Getting the groups with
7 matches
Mail list logo