Request for implementing Sync/Send trait for Row and ResultSet
Opened this issue · 2 comments
zhaopinglu commented
So we can access the rows of the result set of call like conn.query_named in an async function.
Then call this async function with tokio spawn.
Thanks.
zhaopinglu commented
My temporary workaround. FYI:
Add the following lines into src/row.rs:
unsafe impl Sync for Row {}
unsafe impl Send for Row {}
unsafe impl<'a, T> Sync for ResultSet<'a, T> where T: RowValue {}
unsafe impl<'a, T> Send for ResultSet<'a, T> where T: RowValue {}
zhaopinglu commented
Please find the sample code in:
https://github.com/zhaopinglu/qinghe/blob/084e41728b272d73f5e851767ac205ab51b14d75/src/ora2my/export_data.rs#L304