I'm working on a server that uses Prisma Client Rust to interact with its database. One of its endpoints needs to run multiple find_many queries, so I'm trying to batch them into a single request. My code looks something like this:
use crate::prisma::my_object::{Data, FindMany};
let db: &PrismaClient = todo!();
let queries: (FindMany, FindMany) = todo!();
let results = db
._batch(queries)
.await
.unwrap();
Now, I would expect results to be a tuple with one item corresponding to each item in queries and containing a Vec<Data> since each FindMany query should return a Vec<Data>.
However, the actual type of results is (Data, Data).
Is my code wrong, or is this another code generation bug?
I'm working on a server that uses Prisma Client Rust to interact with its database. One of its endpoints needs to run multiple
find_many
queries, so I'm trying to batch them into a single request. My code looks something like this:Now, I would expect
results
to be a tuple with one item corresponding to each item inqueries
and containing aVec<Data>
since eachFindMany
query should return aVec<Data>
.However, the actual type of
results
is(Data, Data)
.Is my code wrong, or is this another code generation bug?