pgcopy 0.0.2

PostgreSQL binary COPY format generator
Documentation

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