Closed as not planned
Description
Bug Description
let mut sql = String::from("select * from user");
// append sql content
...
let arr = sqlx::query!(sql.as_str()).fetch_all(pool).await?;(error: expected string literal)
but:
let arr = sqlx::query!("select * from user").fetch_all(pool).await?;(it's ok)
Minimal Reproduction
A small code snippet or a link to a Github repo or Gist, with instructions on reproducing the bug.
Info
- SQLx version: 0.7.2
- SQLx features enabled: runtime-tokio、mysql
- Database server and version: MySQL
- Operating system: windows 10
rustc --version
: 1.73.0