Skip to content
This repository has been archived by the owner on Oct 21, 2022. It is now read-only.

Commit

Permalink
update documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
lakhassane committed May 20, 2021
1 parent 5fdcc49 commit d81cb8c
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,17 @@ upsert(
);
```

## Insert or Update if a value exist in the record

This function will upsert a record only if the logical given is true. In this case we check if `dataValue('name')` exists.

```js
upsertIf(dataValue('name'), 'users', 'ON CONSTRAINT users_pkey', {
name: 'Elodie',
id: 7,
});
```

## Insert many records in postgresql

This function allows the insert of a set of records inside a table all at once.
Expand Down

0 comments on commit d81cb8c

Please sign in to comment.