From 2eea92bf1d7d68645588af66fcaca238969553b9 Mon Sep 17 00:00:00 2001 From: AlejandroLanaspa Date: Wed, 23 Oct 2024 11:57:24 +0200 Subject: [PATCH] feat: expand examples of queries --- crates/proof-of-sql/examples/movies/main.rs | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/crates/proof-of-sql/examples/movies/main.rs b/crates/proof-of-sql/examples/movies/main.rs index 2300b3aa0..a5cf40c84 100644 --- a/crates/proof-of-sql/examples/movies/main.rs +++ b/crates/proof-of-sql/examples/movies/main.rs @@ -118,4 +118,12 @@ fn main() { &prover_setup, &verifier_setup, ); + + // Query 3: Calculate the average duration of movies by genre + prove_and_verify_query( + "SELECT genre, AVG(duration) AS avg_duration FROM movies GROUP BY genre ORDER BY avg_duration DESC", + &accessor, + &prover_setup, + &verifier_setup, + ); } \ No newline at end of file