File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -79,7 +79,7 @@ fn main() {
7979Connect to a Postgres server using the standard URI format:
8080``` rust
8181let conn = try ! (Connection :: connect (" postgres://user:pass@host:port/database?arg1=val1&arg2=val2" ,
82- & NoSsl ));
82+ & SslMode :: None ));
8383```
8484` pass ` may be omitted if not needed. ` port ` defaults to ` 5432 ` and ` database `
8585defaults to the value of ` user ` if not specified. The driver supports ` trust ` ,
@@ -89,7 +89,7 @@ Unix domain sockets can be used as well. The `host` portion of the URI should be
8989set to the absolute path to the directory containing the socket file. Since ` / `
9090is a reserved character in URLs, the path should be URL encoded.
9191``` rust
92- let conn = try ! (Connection :: connect (" postgres://postgres@%2Frun%2Fpostgres" , & NoSsl ));
92+ let conn = try ! (Connection :: connect (" postgres://postgres@%2Frun%2Fpostgres" , & SslMode :: None ));
9393```
9494Paths which contain non-UTF8 characters can be handled in a different manner;
9595see the documentation for details.
You can’t perform that action at this time.
0 commit comments