Open TaQuanMinhLong opened 1 year ago
Hey, can we add a function for postgres array text, something similar or better than this?
use serde::Serialize; use sql_builder::quote; use std::fmt::Display; pub fn pg_array<T: Display + Serialize>(value: &[T]) -> String { quote( serde_json::to_string(value) .expect("Failed to serialize value") .replace("[", "{") .replace("]", "}"), ) }
Hey, can we add a function for postgres array text, something similar or better than this?