Skip to content

Commit f6dd943

Browse files
samalexandersushantdhiman
authored andcommitted
fix(types): enhance having parameters (#10733)
1 parent 4d5be9a commit f6dd943

File tree

2 files changed

+7
-2
lines changed

2 files changed

+7
-2
lines changed

types/lib/model.d.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -447,9 +447,9 @@ export interface FindOptions extends Logging, Transactionable, Filterable, Proje
447447
raw?: boolean;
448448

449449
/**
450-
* having ?!?
450+
* Select group rows after groups and aggregates are computed.
451451
*/
452-
having?: WhereAttributeHash;
452+
having?: WhereOptions;
453453

454454
/**
455455
* Use sub queries (internal)

types/test/where.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -256,3 +256,8 @@ where = {
256256
where = whereFn('test', {
257257
[Op.gt]: new Date(),
258258
});
259+
260+
// Where as having option
261+
MyModel.findAll({
262+
having: where
263+
});

0 commit comments

Comments
 (0)