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
Shows incorrect count number by using selectRelationCount previewFeatures #8050
Comments
Hey @ikramhasib007, can you share an example schema and script so we can reproduce? |
Queries resolvers
@matthewmueller , check out the source code. |
Have the similar problem here, even without using Schema:
Query:
Result (attention to groups with id 12 and 14):
|
Thanks for the details, I can reproduce this now. Posted minimal reproduction here: https://github.com/harshit-test-org/prisma-issue-8050 |
I'm seeing this happen on 2.30.3 - have tried removing where, skip / take, orderBy, without success. Counts and length of selected relations don't match.
|
Can you open a separate issue please @mart2967 and provide all the information the issue template asks for? Thanks. |
I have a list of posts and each post has multiple comments. I was counting the total comments that each post has. Using
selectRelationCount
previewFeatures, its count number is correct but it shows different references. like:post id
1
has2
commentspost id
2
has4
commentspost id
3
has0
commentpost id
4
has0
commentquery result shows:
post id
1
has0
commentspost id
2
has0
commentspost id
3
has4
commentpost id
4
has2
commentQuery:
The text was updated successfully, but these errors were encountered: