Partition lists when needed

Fixes #1022 
Yes. I will fix it.
On 5 Nov 2014 10:59, "Ruben Dijkstra" <notifications@github.com> wrote:

> In querydsl-sql/src/main/java/com/mysema/query/sql/SQLSerializer.java:
>
> > @@ -877,10 +877,29 @@ protected void visitOperation(Class<?> type, Operator<?> operator, List<? extend
> >
> >          } else if ((operator == Ops.IN || operator == Ops.NOT_IN)
> >                  && args.get(0) instanceof Path
> > -                && args.get(1) instanceof Constant
> > -                && ((Constant<Collection>)args.get(1)).getConstant().isEmpty()) {
> > -            super.visitOperation(type, operator == Ops.IN ? Ops.EQ : Ops.NE,
> > -                    ImmutableList.of(NumberTemplate.ONE, NumberTemplate.TWO));
> > +                && args.get(1) instanceof Constant) {
> > +            Collection<Object> coll = ((Constant<Collection>)args.get(1)).getConstant();
> > +            if (coll.isEmpty()) {
> > +                super.visitOperation(type, operator == Ops.IN ? Ops.EQ : Ops.NE,
> > +                        ImmutableList.of(NumberTemplate.ONE, NumberTemplate.TWO));
> > +            } else {
> > +                if (templates.getListMaxSize() == 0 || coll.size() <= templates.getListMaxSize()) {
> > +                    super.visitOperation(type, operator, args);
> > +                } else {
> > +                    if (!constantPaths.isEmpty()) {
>
> I think you meant to use pathAdded here?
>
> —
> Reply to this email directly or view it on GitHub
> <https://github.com/querydsl/querydsl/pull/1026/files#r19860988>.
>