Hi Nat,

On Thu, Aug 15, 2019 at 6:52 PM Nathaniel Mishkin <mish...@aya.yale.edu>
wrote:

>
> On Mon, Aug 5, 2019 at 10:22 AM Knut Wannheden <knut.wannhe...@gmail.com>
> wrote:
>
>> (1) A workaround I can think of would be to put limit() before window(),
>> but I suppose that is not the answer you were looking for. It would also
>> require your limit() call to account for the window size (e.g. when calling
>> window(-1, 1) and a desired limit of 10 you would first have to call
>> limit(11)).
>>
>
> Unfortunately, the logic of what I'm trying to do requires the *limit()* to
> be after the *window()*.
>

What I meant was that you could call limit() before *and* after calling
window(). The first call to limit() would have to account for the window
size. So instead of calling seq.window(-1, 1).limit(10) you would call
seq.limit(11).window(-1, 1).limit(10). Hope this makes more sense now.

(2) We will first have to discuss this problem with Lukas, when he returns
>> from vacation next week.
>>
>
> Any update on this? Did Lukas have a good vacation? :-)
>

No update yet. But he is indeed back from his vacation, so we should get
back to you soon regarding this.


> FYI this issue is happening in some existing code where I in fact have the
> *limit()* before the *window()* but I recently realized that that order
> is incorrect. I have a pretty complicated pipeline and what I need to do is
> limit the ultimate number of elements produced by the stream, not the
> number of elements that happen to be "passing by" and earlier stage of the
> stream. I'd really hate to have to re-write this all in iterative form.
>

Makes sense.

Knut

-- 
You received this message because you are subscribed to the Google Groups "jOOQ 
User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jooq-user+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jooq-user/CAFx%3DKgemMZq5V%3DROdrBJ2MweVRkZU-vnW1maADKYDO4NRta-yA%40mail.gmail.com.

Reply via email to