Skip to content

Commit 8ff0055

Browse files
committed
Update docs
1 parent 999e4c5 commit 8ff0055

File tree

1 file changed

+16
-6
lines changed

1 file changed

+16
-6
lines changed

MODULE.md

Lines changed: 16 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -37,15 +37,15 @@ type ConnectionInfo = { password :: String, user :: String, port :: Number, db :
3737
connect :: forall eff. ConnectionInfo -> Aff (db :: DB | eff) Client
3838
```
3939

40-
Makes a connection to the database
40+
Makes a connection to the database.
4141

4242
#### `execute`
4343

4444
``` purescript
4545
execute :: forall eff a. Query a -> [SqlValue] -> Client -> Aff (db :: DB | eff) Unit
4646
```
4747

48-
Runs a query and returns nothing
48+
Runs a query and returns nothing.
4949

5050
#### `execute_`
5151

@@ -61,7 +61,7 @@ Runs a query and returns nothing
6161
query :: forall eff a p. (IsForeign a) => Query a -> [SqlValue] -> Client -> Aff (db :: DB | eff) [F a]
6262
```
6363

64-
Runs a query and returns all results
64+
Runs a query and returns all results.
6565

6666
#### `query_`
6767

@@ -93,7 +93,7 @@ Just like `queryOne` but does not make any param replacement
9393
queryValue :: forall eff a. (IsForeign a) => Query a -> [SqlValue] -> Client -> Aff (db :: DB | eff) (Maybe a)
9494
```
9595

96-
Runs a query and returns a single value, if any
96+
Runs a query and returns a single value, if any.
9797

9898
#### `queryValue_`
9999

@@ -112,6 +112,16 @@ withConnection :: forall eff a. ConnectionInfo -> (Client -> Aff (db :: DB | eff
112112
Connects to the database, calls the provided function with the client
113113
and returns the results.
114114

115+
#### `end`
116+
117+
``` purescript
118+
end :: forall eff. Client -> Eff (db :: DB | eff) Unit
119+
```
120+
121+
122+
123+
## Module Database.Postgres.SqlValue
124+
115125
#### `SqlValue`
116126

117127
``` purescript
@@ -148,10 +158,10 @@ instance isSqlValueInt :: IsSqlValue Int
148158
```
149159

150160

151-
#### `end`
161+
#### `isSqlValueMaybe`
152162

153163
``` purescript
154-
end :: forall eff. Client -> Eff (db :: DB | eff) Unit
164+
instance isSqlValueMaybe :: (IsSqlValue a) => IsSqlValue (Maybe a)
155165
```
156166

157167

0 commit comments

Comments
 (0)