| Hannu Krosing 2005-09-16, 7:23 am |
| On K, 2005-08-10 at 17:39 -0400, Christopher Browne wrote:
> Hannu Krosing <hannu-7C/ iILuz2RdeoWH0uzbU5w@
public.gmane.org> writes:
>
> I have a patch that passes the "test_1_pgbench" test, which definitely
> exercises it. (Albeit not with Just Insanely Big Queries...)
>
> If the set of "actionseq" values are being returned in random order,
> it won't turn out terribly well, but if they are in even a fairly
> approximate ordering, it'll be a BIG help. And it looks as though
> they are returned more or less in order.
>
> I'd like for someone else to "use this patch in anger" before I
> consider adding it into CVS HEAD.
>
> In particular, can Jan comment on how sl_setsync gets populated? Do I
> get to assume a reasonably strong ordering of the elements embedded in
> sl_setsync.ssy_action_list?
>
I found myself again in a situation wher I had to test your patch :)
as all my 650K ids were consecutive it produced a subclause ending in
"and ( )" and thus a ayntax error.
I digged a little, and found out that it was missing the final (after
the loop) part.
so this part of
> + state = BETWEEN_NUMBERS;
> + curr_number = 0;
> + }
> + ssy_actionlist++;
> + }
should be expanded to this to produce results and not leave out the last
range. (which in my case was the *whole* range :) )
state = BETWEEN_NUMBERS;
curr_number = 0;
}
ssy_actionlist++;
}
/* process last range, if it exists */
if ( curr_min || curr_max) {
if (first_subquery) {
first_subquery = 0;
} else {
slon_appendquery(act
ion_subquery, " and ");
}
if (curr_max == curr_min) {
slon_log(SLON_DEBUG1
, "simple entry - %d\n", curr_max);
slon_appendquery(act
ion_subquery,
" log_actionseq <> '%d' ", curr_max);
} else {
slon_log(SLON_DEBUG1
, "between entry - %d %d\n",
curr_min, curr_max);
slon_appendquery(act
ion_subquery,
" log_actionseq not between '%d' and '%d' ",
curr_min, curr_max);
}
--
Hannu Krosing <hannu-7C/ iILuz2RdeoWH0uzbU5w@
public.gmane.org>
|