Skip to content
This repository has been archived by the owner on Sep 26, 2023. It is now read-only.

Commit

Permalink
add ilike operator (#886)
Browse files Browse the repository at this point in the history
  • Loading branch information
sylvainlap authored and daffl committed Oct 26, 2017
1 parent 7fb62a1 commit b302cd4
Showing 1 changed file with 20 additions and 0 deletions.
20 changes: 20 additions & 0 deletions api/databases/knexjs.md
Original file line number Diff line number Diff line change
Expand Up @@ -161,6 +161,26 @@ Through the REST API:
/messages?text[$like]=Hello%
```

### $ilike

For PostgreSQL only, the keywork $ilike can be used instead of $like to make the match case insensitive. The following query retrieves all messages that start with `hello` (case insensitive):

```js
app.service('messages').find({
query: {
text: {
$ilike: 'hello%'
}
}
});
```

Through the REST API:

```
/messages?text[$ilike]=hello%
```


## Transaction Support

Expand Down

0 comments on commit b302cd4

Please sign in to comment.