goldmedal commented on issue #10688:
URL: https://github.com/apache/datafusion/issues/10688#issuecomment-2139760705

   Indeed, it's a conversion issue. I tried to dig into the root cause and 
found that arrow-cast uses the crate [num](https://crates.io/crates/num) to 
handle casting problems. I tried to use it directly:
   ```
       let value_32: f32 = 128.2;
       println!("value_32: {:?}", value_32);
       let value_64: f64 = num::cast(value_32).unwrap();
       println!("value_64: {:?}", value_64);
   -------------------
   value_32: 128.2
   value_64: 128.1999969482422
   ```
   I have no idea how to fix it in DataFusion. Maybe we need to go back to the 
crate `num` to fix this behavior?
   @comphead  WDYT?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscr...@datafusion.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: github-unsubscr...@datafusion.apache.org
For additional commands, e-mail: github-h...@datafusion.apache.org

Reply via email to