mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2026-02-28 11:43:00 +00:00
Add a couple of tests showing how the null value would be used in a where filter
This commit is contained in:
parent
a2093850ab
commit
0e019bd7f9
@ -185,6 +185,10 @@ knex('users').where(() => {
|
||||
|
||||
knex('users').where('votes', '>', 100);
|
||||
|
||||
// Let null be used in a two or 3 parameter where filter
|
||||
knex('users').where('votes', null);
|
||||
knex('users').where('votes', 'is not', null);
|
||||
|
||||
var subquery = knex('users').where('votes', '>', 100).andWhere('status', 'active').orWhere('name', 'John').select('id');
|
||||
knex('accounts').where('id', 'in', subquery);
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user