* Try to fix bug #36385.

This commit is contained in:
songchenxuan
2023-07-11 09:37:42 +08:00
parent 92ae511b42
commit 07963e065b
+8 -1
View File
@@ -1539,7 +1539,14 @@ class pivotModel extends model
}
else
{
$columnSQL = "$stat(tt.`$field`) as `$uuName`";
if($fields[$field]['type'] == 'number')
{
$columnSQL = "$stat(tt.`$field`) as `$uuName`";
}
else
{
$columnSQL = "$stat(0) as `$uuName`";
}
}
if($slice != 'noSlice') $columnSQL = "select $groupList,`$slice`,$columnSQL from ($sql) tt" . $connectSQL . $groupSQL . ",tt.`$slice`" . $orderSQL . ",tt.`$slice`";