Crates.io | edgedb-query-builder |
lib.rs | edgedb-query-builder |
version | 0.1.2 |
source | src |
created_at | 2022-07-31 21:59:56.388303 |
updated_at | 2022-07-31 22:10:49.63393 |
description | A query builder for Edgedb written in Rust |
homepage | |
repository | https://github.com/ibx34/edgedb-query-builder |
max_upload_size | |
id | 636369 |
size | 5,122 |
dont judge it too hard please....// This crate is still VERY VERY in dev. Below is a simple example of how to insert something and select it.
let new_movie_name = String::from("Ferris, a true story.");
let query = Query::new().insert("Movie", vec![(String::from("title"), new_movie_name.to_owned())]).build();
conn.query_single::<Movie2, _>(
&query,
&(),
).await?;
let query = Query::new().select("Movie", vec!["id", "title"]).filter(vec![(String::from("title"), new_movie_name)]).build();
let val = conn.query::<Movie, _>(
&query,
&(),
).await?;