-
Notifications
You must be signed in to change notification settings - Fork 236
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
19 changed files
with
57 additions
and
43 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
//go:build !pq | ||
// +build !pq | ||
|
||
// Copyright (c) 2012-present The upper.io/db authors. All rights reserved. | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
//go:build pq | ||
// +build pq | ||
|
||
// Copyright (c) 2012-present The upper.io/db authors. All rights reserved. | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -77,14 +77,14 @@ func (vs values) Isset(k string) bool { | |
// | ||
// You can use a ConnectionURL struct as an argument for Open: | ||
// | ||
// var settings = postgresql.ConnectionURL{ | ||
// Host: "localhost", // PostgreSQL server IP or name. | ||
// Database: "peanuts", // Database name. | ||
// User: "cbrown", // Optional user name. | ||
// Password: "snoopy", // Optional user password. | ||
// } | ||
// var settings = postgresql.ConnectionURL{ | ||
// Host: "localhost", // PostgreSQL server IP or name. | ||
// Database: "peanuts", // Database name. | ||
// User: "cbrown", // Optional user name. | ||
// Password: "snoopy", // Optional user password. | ||
// } | ||
// | ||
// sess, err = postgresql.Open(settings) | ||
// sess, err = postgresql.Open(settings) | ||
// | ||
// If you already have a valid DSN, you can use ParseURL to convert it into | ||
// a ConnectionURL before passing it to Open. | ||
|
@@ -104,7 +104,7 @@ var escaper = strings.NewReplacer(` `, `\ `, `'`, `\'`, `\`, `\\`) | |
// ParseURL parses the given DSN into a ConnectionURL struct. | ||
// A typical PostgreSQL connection URL looks like: | ||
// | ||
// postgres://bob:[email protected]:5432/mydb?sslmode=verify-full | ||
// postgres://bob:[email protected]:5432/mydb?sslmode=verify-full | ||
func ParseURL(s string) (u *ConnectionURL, err error) { | ||
o := make(values) | ||
|
||
|
@@ -260,7 +260,7 @@ func newScanner(s string) *scanner { | |
// | ||
// "postgres://" | ||
// | ||
// This will be blank, causing driver.Open to use all of the defaults | ||
// # This will be blank, causing driver.Open to use all of the defaults | ||
// | ||
// NOTE: vendored/copied from github.com/lib/pq | ||
func parseURL(uri string) (string, error) { | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
//go:build !pq | ||
// +build !pq | ||
|
||
// Copyright (c) 2012-present The upper.io/db authors. All rights reserved. | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
//go:build pq | ||
// +build pq | ||
|
||
package postgresql | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
//go:build !go1.8 | ||
// +build !go1.8 | ||
|
||
package compat | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
//go:build go1.8 | ||
// +build go1.8 | ||
|
||
package compat | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters