rust-postgres-query:轻松编写和执行SQL查询

时间:2021-05-23 05:18:59
【文件属性】:
文件名称:rust-postgres-query:轻松编写和执行SQL查询
文件大小:48KB
文件格式:ZIP
更新时间:2021-05-23 05:18:59
Rust Postgres查询 此板条箱提供了便利的宏和特征,可帮助编写SQL查询并将其结果收集到静态类型的结构中。 例子 // Connect to the database let client: Client = connect ( /* ... */ ); // Construct the query let query = query! ( "SELECT name, age FROM people WHERE age >= $min_age" , min_age = 18 ); // Define the structure of the data returned from the query #[derive(FromSqlRow)] struct Person { age: i32 , name: String , } // Execute th
【文件预览】:
rust-postgres-query-master
----LICENSE-MIT(1023B)
----Cargo.toml(77B)
----.github()
--------workflows()
----postgres_query()
--------Cargo.toml(924B)
--------src()
--------examples()
--------tests()
----LICENSE-APACHE(11KB)
----.travis.yml(256B)
----README.md(5KB)
----postgres_query_macro()
--------Cargo.toml(472B)
--------src()
----.gitignore(117B)

网友评论