comphead commented on issue #10688: URL: https://github.com/apache/datafusion/issues/10688#issuecomment-2138584100
good catch, we can check that Even simple conversion gives weird result ``` let expr2 = ScalarValue::Float32(Some(128.2)) .cast_to(&DataType::Float64) .unwrap() ; println!("expr2: {:?}", expr2); expr2: Float64(128.1999969482422) ``` Opposite conversion is ok though ``` let expr2 = ScalarValue::Float64(Some(128.2)) .cast_to(&DataType::Float32) .unwrap(); println!("expr2: {:?}", expr2); expr2: Float32(128.2) ``` For me looks like a conversion issue, especially strange its happening when we convert into larger precision. -- 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