> I managed to find out which table is the offender, even just joining without selecting any colums from that table makes odata v2 only show 36 records.
That sounds very odd indeed. The only similar issue that I'm aware of is [TEIID-4852] Wrong OData results with multiple self relationships - JBoss Issue Tracker That shouldn't be your issue though if it works with odata4. Can you raise a support ticket on this? OData2 generation was removed from the community in 9.1 [TEIID-3754] Remove OData V2 implementation of the Server - JBoss Issue Tracker - so a community issue alone won't help.
Somehow there was something wrong with the join, a more experienced SQL developer fixed it. Lucky there was nothing wrong with OData as far as I can tell.
> Lucky there was nothing wrong with OData as far as I can tell.
Thanks for the update. That is good news.