Hello,

I'll comment inline...

2017-05-13 16:10 GMT+02:00 <[email protected]>:

> Hi Team, I hope you are doing great. I need few suggestions about below
> query
>
> Select a.*
> From TableA a,
>      TableB b,
>      TableC c,
>      TableD d
> Where a.id = 1234
>  and a.id = b.id
>  and a.id = c.id
>  and c.deptNo = d.deptNo
>  and c.name in ('Name1', 'Name2')
>
> tableA and TableD doesn't not have any relation ship.
>

Why would you join TableD this way? You're creating a seemingly meaningless
cartesian product between (a, b, c) and (d).


> Can we get count(*) from above query then will check rows doesn't exceed
> the specified limit then will select the fields from TableA
>
> Could you please provide equalant Jooq code for above query?
> Iam just trying wil SelectQuery but not able to achieve.  Could you please
> help on this.   Thanks in advance
>

Before I'll have a go at this, would you mind explaining:

1) What you're trying to achieve (perhaps with real table names. It's
always easier this way)
2) What you mean by getting "count(*) from the above query" (again,
probably easier to answer with a real use-case in mind)
3) What you have tried already with jOOQ and where you're stuck

Cheers,
Lukas

-- 
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