sqlx icon indicating copy to clipboard operation
sqlx copied to clipboard

🧰 The Rust SQL Toolkit. An async, pure Rust SQL crate featuring compile-time checked queries without a DSL. Supports PostgreSQL, MySQL, and SQLite.

Results 570 sqlx issues
Sort by recently updated
recently updated
newest added

I have installed sqlx 0.5.1 with the features `["runtime-tokio-rustls", "macro", "postgres"]` on Windows 10 (Build 21332.1000) with Rust stable 1.50.0. However using `sqlx::query!("SELECT opt FROM users WHERE id = $1...

Currently sqlx requires one of the runtime-* features enabled. However, when using sqlx in a crate that only defines types and derives FromRow it may be a little problematic, because...

I'm getting an error message when running cargo sqlx prepare saying extra arguments to rustc can only be passed to one target. Create database and migrate both work with Postgres,...

enhancement
E-medium
cli

## Question I understand that in order to get data from a table I need to define a struct with the data I expect, and for specific queries I can...

I'm using a `FromRow` from my main model structure: ```rust #[derive(sqlx::FromRow)] struct MyUser { email: Option, } ``` With my `Email` being defined like shown, similar to the [docs](https://docs.rs/sqlx/latest/sqlx/trait.Type.html#transparent): ```rust...

I'm trying to follow the quickstart with SQLite: ``` // in .env, DATABASE_URL=/absolute/path/to/database.db struct ResultStruct; async fn reproduce_bug() -> Result { let pool = SqlitePoolOptions::new().max_connections(5).connect("/absolute/path/to/database.db").await; sqlx::query_as!( ResultStruct, " SELECT *...

# Status Quo Currently, the default mode of operation for the `sqlx::query!()` family of macros is to connect to a running database server (or open that database in-process for SQLite)...

macros
proposal

Hello! I am opening an issue to discuss Postgres type resolution. I submitted some PRs related to this code, but these were incremental changes. I'd like to discuss a larger...

I have the following enum and struct: ```rust #[derive(sqlx::Type, Debug)] #[sqlx(rename = "service_state", rename_all = "SCREAMING_SNAKE_CASE")] pub enum ServiceState { Available, NotAvailable, } pub struct ServiceStatus { pub ip: String,...

Seems like the line in question is [here](https://github.com/launchbadge/sqlx/blob/a47068257284ee8405bfbcf6240d89edb8502598/sqlx-core/src/mysql/types/time.rs#L194). I know that 0000... is an invalid date, but it would be preferable for sqlx to return None instead of panicking.