impl sqlx::postgres::PgHasArrayType for Snowflake

This commit is contained in:
bitfl0wer 2024-08-20 15:28:27 +02:00
parent a8b747f1ef
commit a561b61321
No known key found for this signature in database
GPG Key ID: 8D90CA11485CD14D
1 changed files with 7 additions and 0 deletions

View File

@ -102,6 +102,13 @@ impl sqlx::Type<sqlx::Postgres> for Snowflake {
} }
} }
#[cfg(feature = "sqlx")]
impl sqlx::postgres::PgHasArrayType for Snowflake {
fn array_type_info() -> sqlx::postgres::PgTypeInfo {
<Vec<String> as sqlx::Type<sqlx::Postgres>>::type_info()
}
}
#[cfg(feature = "sqlx")] #[cfg(feature = "sqlx")]
impl<'q> sqlx::Encode<'q, sqlx::Postgres> for Snowflake { impl<'q> sqlx::Encode<'q, sqlx::Postgres> for Snowflake {
fn encode_by_ref( fn encode_by_ref(