Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Using order by on a distinct query #181

Closed
olaf-matthes opened this issue Apr 14, 2022 · 0 comments
Closed

Using order by on a distinct query #181

olaf-matthes opened this issue Apr 14, 2022 · 0 comments

Comments

@olaf-matthes
Copy link

I have a query using distinct that is converted to a fetch.xml using distinct='true', so the server does the distinct and all is fine
If I add an order by clause, sql4cds decides to do the distinct on client side, which is a poor idea cause of rows > 500.000 and so hitting retrieval limit

Easy example:
select distinct statecode from contact order by statecode

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant