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

[5.x] Fix "Top Customers" query when storing users in a database #977

Merged
merged 2 commits into from
Jan 20, 2024

Conversation

duncanmcclean
Copy link
Owner

@duncanmcclean duncanmcclean commented Jan 20, 2024

This pull request attempts to fix an issue where the query for the "Top Customers" widget on the Overview sometimes caused a database error, depending on the version of MySQL you have installed.

To resolve the issue for those using MySQL, I've adjusted the query to use the JSON_LENGTH function instead. However, since SQLite doesn't support this function, it'll continue to use the working JSON_ARRAY_LENGTH function.

Fixes #906.

duncanmcclean added a commit that referenced this pull request Jan 20, 2024
@duncanmcclean duncanmcclean marked this pull request as ready for review January 20, 2024 17:25
@duncanmcclean duncanmcclean merged commit bf9e1de into 5.x Jan 20, 2024
7 checks passed
@duncanmcclean duncanmcclean deleted the fix/top-customers-query branch January 20, 2024 17:34
Copy link

Released as part of v5.9.2.

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

Successfully merging this pull request may close these issues.

Top Customer widget not working with eloquent users
1 participant