| Crates.io | snowflake-connector-rs |
| lib.rs | snowflake-connector-rs |
| version | 0.7.6 |
| created_at | 2023-12-04 13:22:08.704834+00 |
| updated_at | 2026-01-20 08:22:52.509895+00 |
| description | A Rust client for Snowflake |
| homepage | |
| repository | https://github.com/estie-inc/snowflake-connector-rs |
| max_upload_size | |
| id | 1057602 |
| size | 123,885 |
A Rust client for Snowflake, which enables you to connect to Snowflake and run queries.
let client = SnowflakeClient::new(
"USERNAME",
SnowflakeAuthMethod::Password("PASSWORD".to_string()),
SnowflakeClientConfig {
account: "ACCOUNT".to_string(),
role: Some("ROLE".to_string()),
warehouse: Some("WAREHOUSE".to_string()),
database: Some("DATABASE".to_string()),
schema: Some("SCHEMA".to_string()),
timeout: Some(std::time::Duration::from_secs(30)),
},
)?;
let session = client.create_session().await?;
let query = "CREATE TEMPORARY TABLE example (id NUMBER, value STRING)";
session.query(query).await?;
let query = "INSERT INTO example (id, value) VALUES (1, 'hello'), (2, 'world')";
session.query(query).await?;
let query = "SELECT * FROM example ORDER BY id";
let rows = session.query(query).await?;
assert_eq!(rows.len(), 2);
assert_eq!(rows[0].get::<i64>("ID")?, 1);
assert_eq!(rows[0].get::<String>("VALUE")?, "hello");
This crate supports optional features to decrypt legacy keys that use DES or 3DES encryption. These algorithms are considered insecure and should only be used for legacy compatibility.
pkcs8-des: Enables DES decryption supportpkcs8-3des: Enables 3DES decryption support