petern48 opened a new issue, #20:
URL: https://github.com/apache/sedona-db/issues/20

   Despite the error saying it's DataFusion's code, I suspect this is really 
our bug and we're just using `DataFusionError::Internal` somewhere or 
`internal_err!`, which returns this misleading bug, as mentioned in this 
previous PR: https://github.com/apache/sedona-db/pull/2
   
   ```sql
   > select st_buffer(st_geomfromtext('point (0 0)'), 1);
   Internal error: Cannot convert Int64(1) to f64.
   This issue was likely caused by a bug in DataFusion's code. Please help us 
to resolve this by filing a bug report in our issue tracker: 
https://github.com/apache/datafusion/issues
   
   -- Now, add a ".0" to make it a float, and it now works
   > select st_buffer(st_geomfromtext('point (0 0)'), 1.0);
   
┌──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┐
   │                                   st_buffer(st_geomfromwkt(Utf8("point (0 
0)")),Float64(1))                                  │
   │                                                              wkb           
                                                  │
   
╞══════════════════════════════════════════════════════════════════════════════════════════════════════════════════════════════╡
   │ POLYGON((1 0,0.9807852804032304 -0.19509032201612825,0.9238795325112867 
-0.3826834323650898,0.8314696123025452 -0.555570233… │
   
└──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┘
   ```
   
   The same happens with `select st_dwithin(st_geomfromtext('point (0 0)'), 
st_geomfromtext('point (0 0)'), 1);`
   
   Datafusion functions like max() still work with ints properly
   ```sql
   select max(1);
   ┌───────────────┐
   │ max(Int64(1)) │
   │     int64     │
   ╞═══════════════╡
   │             1 │
   └───────────────┘
   ```


-- 
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: issues-unsubscr...@sedona.apache.org.apache.org

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

Reply via email to