mirror of
https://github.com/DeNNiiInc/dbgate.git
synced 2026-04-22 06:26:00 +00:00
query designer - grop filter (having clause)
This commit is contained in:
@@ -36,6 +36,11 @@ export function dumpSqlSelect(dmp: SqlDumper, cmd: Select) {
|
||||
dmp.putCollection(', ', cmd.groupBy, (expr) => dumpSqlExpression(dmp, expr));
|
||||
dmp.put('&n');
|
||||
}
|
||||
if (cmd.having) {
|
||||
dmp.put('&n^having ');
|
||||
dumpSqlCondition(dmp, cmd.having);
|
||||
dmp.put('&n');
|
||||
}
|
||||
if (cmd.orderBy) {
|
||||
dmp.put('&n^order ^by ');
|
||||
dmp.putCollection(', ', cmd.orderBy, (expr) => {
|
||||
|
||||
@@ -16,6 +16,7 @@ export interface Select {
|
||||
orderBy?: OrderByExpression[];
|
||||
groupBy?: Expression[];
|
||||
where?: Condition;
|
||||
having?: Condition;
|
||||
}
|
||||
|
||||
export type UpdateField = Expression & { targetColumn: string };
|
||||
|
||||
Reference in New Issue
Block a user