mirror of
https://github.com/DeNNiiInc/dbgate.git
synced 2026-05-02 02:03:58 +00:00
group by - count on identity
This commit is contained in:
@@ -282,7 +282,10 @@ export abstract class GridDisplay {
|
|||||||
|
|
||||||
getGrouping(uniqueName): GroupFunc {
|
getGrouping(uniqueName): GroupFunc {
|
||||||
if (this.isGrouped) {
|
if (this.isGrouped) {
|
||||||
return this.config.grouping[uniqueName] || 'MAX';
|
if (this.config.grouping[uniqueName]) return this.config.grouping[uniqueName];
|
||||||
|
const column = this.baseTable.columns.find((x) => x.columnName == uniqueName);
|
||||||
|
if (column?.autoIncrement) return 'COUNT';
|
||||||
|
return 'MAX';
|
||||||
}
|
}
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user