2
0

Add support for integer, float and text arrays

Restructure internals a bit so pgx/stdlib can turn off binary encoding and
receive text back for array types.
This commit is contained in:
Jack Christensen
2014-07-26 15:03:52 -05:00
parent b06d71f684
commit e29574d447
8 changed files with 864 additions and 44 deletions
+9 -4
View File
@@ -70,9 +70,6 @@ if err != nil {
}
```
Prepared statements will use the binary transmission when possible. This can
substantially increase performance.
### Explicit Connection Pool
Connection pool usage is explicit and configurable. In pgx, a connection can
@@ -151,9 +148,17 @@ point type.
pgx includes Null* types in a similar fashion to database/sql that implement the
necessary interfaces to be encoded and scanned.
### Array Mapping
pgx maps between int16, int32, int64, float32, float64, and string Go slices
and the equivalent PostgreSQL array type. Go slices of native types do not
support nulls, so if a PostgreSQL array that contains a slice is read into a
native Go slice an error will occur.
### Logging
pgx connections optionally accept a logger from the [log15 package](http://gopkg.in/inconshreveable/log15.v2).
pgx connections optionally accept a logger from the [log15
package](http://gopkg.in/inconshreveable/log15.v2).
## Testing