Skip to content

Count fails when using select within scopes #7407

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

Open
mrf345 opened this issue Apr 4, 2025 · 0 comments · May be fixed by #7408
Open

Count fails when using select within scopes #7407

mrf345 opened this issue Apr 4, 2025 · 0 comments · May be fixed by #7408
Assignees
Labels
type:with reproduction steps with reproduction steps

Comments

@mrf345
Copy link

mrf345 commented Apr 4, 2025

GORM Playground Link

go-gorm/playground#796

Description

When using select within a scope, the Count function fails, with error:

sql: expected 12 destination arguments in Scan, not 1
@github-actions github-actions bot added the type:with reproduction steps with reproduction steps label Apr 4, 2025
mrf345 added a commit to mrf345/gorm that referenced this issue Apr 4, 2025
@mrf345 mrf345 linked a pull request Apr 4, 2025 that will close this issue
3 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type:with reproduction steps with reproduction steps
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants