-
-
Notifications
You must be signed in to change notification settings - Fork 2.6k
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
Count elements in some lists #21444
Comments
…count-element FIX count elements in invoice list (Issue #21444)
To help me understand the issue #21444 can you provide the full SQL request you have when using your external module. String before and after. |
SQL beforeSELECT f.rowid AS id, |
SQL AfterSELECT COUNT(f.rowid) AS nbtotalofrecords |
Fixed with "^SELECT[a-zA-Z0-9._\s(),=<>:-']+\sFROM/Ui" (see product list for best practice : #22882) |
Bug
In some lists, the new way to count elements can occur an SQL error :
In an external module you can use the hook "printFieldListFrom()", to add a subrequest with "LEFT JOIN (SELECT fields FROM table)", and an SQL error occurs when you show this list and you got a blank page.
This new way to build the count SQL request in list, seems to be a good idea to improve memory performances, however it also occurs errors with external modules.
Environment Version
14.0
Environment OS
No response
Environment Web server
No response
Environment PHP
7.3
Environment Database
Mysql
Environment URL(s)
No response
Expected and actual behavior
No response
Steps to reproduce the behavior
No response
Attached files
No response
The text was updated successfully, but these errors were encountered: