Hi Mark,

That's an interesting use-case, and it obviously makes sense the way you
describe it.

I wonder, however, if automatically omitting NULL values from grouped lists
/ nested collections is really correct. In some cases, NULL might be
(ab-)used as a signal by a specific RecordMapper implementation. Another
way to look at it is SQL itself. When you GROUP BY in SQL, you cannot get
an "empty" group in your results. In other words, OUTER JOIN's producing
NULL values and GROUP BY's lack of empty group support are conflicting here
- both in SQL and in Java.

I wonder if there's really a thorough solution for this?

2015-12-08 2:59 GMT+01:00 Mark Derricutt <[email protected]>:

> Hey all,
>
> I'm using context.fetch(...).intoGroups(keyMapper, rowMapper) with a
> query that's LEFT OUTER JOINING the values that end up in the rowMapper
> side of things.
>
> For values where there is nothing, currently I just return null from the
> mapper, but these null values then end up in the List returned from jooq.
>
> Ideally I'd just like to skip those values and elide them from the list,
> so as to not worry about having null checks further down the track.
>
> Is that possible?
>
> --
> Mark Derricutt
> http://www.theoryinpractice.net
> http://www.chaliceofblood.net
> http://plus.google.com/+MarkDerricutt
> http://twitter.com/talios
> http://facebook.com/mderricutt
>
> --
> 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 [email protected].
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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 [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to