Thanks.
Have a feeling I made this same mistake before and posted to this
forum as well ...
RBS
On Wed, Oct 17, 2012 at 4:13 AM, Igor Tandetnik wrote:
> Bart Smissaert wrote:
>> To do with the same, what is wrong with this update SQL?
>>
>>
Bart Smissaert wrote:
> To do with the same, what is wrong with this update SQL?
>
> update final2
> set group_count =
> (select count(*)
> from
> final2
> group by
> group_marker)
>
> It makes group_count always 1
The subquery does not depend on the values in the row
To do with the same, what is wrong with this update SQL?
update final2
set group_count =
(select count(*)
from
final2
group by
group_marker)
It makes group_count always 1, but should include higher values.
The select by itself gives the right result.
RBS
On Wed, Oct 17, 2012 at 12:31 AM, Bart
Without the concatenation it runs fine,
enormously faster than with the concatenation.
Have checked and the result is fine as well.
Thanks again.
RBS
On Tue, Oct 16, 2012 at 11:38 PM, Igor Tandetnik wrote:
> On 10/16/2012 6:29 PM, Bart Smissaert wrote:
>>
>> Actually, it
> From: sqlite-users-boun...@sqlite.org [sqlite-users-boun...@sqlite.org] on
> behalf of Bart Smissaert [bart.smissa...@gmail.com]
> Sent: Tuesday, October 16, 2012 5:45 PM
> To: General Discussion of SQLite Database
> Subject: EXT :Re: [sqlite] fi
s-boun...@sqlite.org] on
behalf of Bart Smissaert [bart.smissa...@gmail.com]
Sent: Tuesday, October 16, 2012 5:45 PM
To: General Discussion of SQLite Database
Subject: EXT :Re: [sqlite] find sequential groups
Thanks, will try that.
Yes, the ID field is an integer primary key autoincrement.
Still
Thanks, will try that.
Yes, the ID field is an integer primary key autoincrement.
Still running the old sql with concatenation. Looks I may need
to kill that.
RBS
On Tue, Oct 16, 2012 at 11:38 PM, Igor Tandetnik wrote:
> On 10/16/2012 6:29 PM, Bart Smissaert wrote:
>>
>>
On 10/16/2012 6:29 PM, Bart Smissaert wrote:
Actually, it really is slow, made worse by the fact that there is not
one grouping
field (value in my example), but three. I am running your SQL now, concatenating
these 3 fields, but still running and looks will be a long time.
Will have to improve
Thanks, very nice solution that!
Yes, I realise that this is a lot faster in code, but for now that is no option.
Actually, it really is slow, made worse by the fact that there is not
one grouping
field (value in my example), but three. I am running your SQL now, concatenating
these 3 fields, but
On 10/16/2012 4:56 PM, Bart Smissaert wrote:
Trying to make a query that can mark records, indicating them to
belong to a sequential group.
Giving the most simple example:
IDValue Group_Marker
---
1 D1
2 X 2
3 X 2
Trying to make a query that can mark records, indicating them to
belong to a sequential group.
Giving the most simple example:
IDValue Group_Marker
---
1 D1
2 X 2
3 X 2
4 X 2
5 A 3
6 B
11 matches
Mail list logo