diesel-citext

Crates.iodiesel-citext
lib.rsdiesel-citext
version0.3.0
sourcesrc
created_at2019-02-08 06:01:41.830034
updated_at2019-02-19 02:32:33.344856
descriptionDiesel support for citext type
homepage
repositoryhttps://github.com/gregelenbaas/diesel-citext
max_upload_size
id113472
size8,503
(gregelenbaas)

documentation

https://docs.rs/diesel-citext

README

diesel-citext  

Diesel support for Postgres citext Extension

Example usage:

This very small extension allows you to use the citext type with diesel, without having to make modifications to the schema.rs generated file. It takes much inspiration from diesel-postgis.

Before sending to postgres and after parsing from postgres, the text content is always passed through the Rust String to_lowercase method.

To Ensure citext in the schema.rs file is parsed correctly, add diesel_citext to the import types declaration in your diesel.toml file.

E.g. it will look like this:

[print_schema]
file = "src/schema.rs"

import_types = ["diesel::sql_types::*", "diesel_citext::sql_types::*"]
Commit count: 13

cargo fmt