2 releases

0.0.2 Feb 7, 2019
0.0.1 Jan 31, 2019

#61 in #binary-serialization


Used in jja

Apache-2.0 OR MIT

29KB
490 lines

pgcopy

Latest Version Latest Version

Write data into a PostgreSQL COPY WITH BINARY format, somewhat faster way to insert a lot of entries into database that plain text or CSV.

Supported data types

PostgreSQL type Rust equivalent
smallint i16
integer i32
bigint i64
decimal
numeric
real f32
double f64
char char
char varying &str
text &str
bytea &[u8]
timestamp chrono::naive::NaiveDateTime
timestamp with time zone chrono::DateTime
date chrono::Date or chrono::naive::NaiveDate
time chrono::naive::NaiveTime
interval
boolean bool
cidr
inet
macaddr [u8; 6] or eui48::MacAddress
macaddr8 [u8; 6], [u8; 8] or eui48::MacAddress
uuid [u8; 16] or uuid::Uuid
xml
json
jsonb
array

Dependencies

~82–495KB