Skip to content

Commit

Permalink
debug
Browse files Browse the repository at this point in the history
  • Loading branch information
dadepo committed Dec 17, 2023
1 parent db5181d commit e17bb2e
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/rust.yml
Original file line number Diff line number Diff line change
Expand Up @@ -113,4 +113,4 @@ jobs:
- name: Build
run: cargo build --verbose
- name: Run tests
run: cargo test --all-features --verbose -- --nocapture
run: cargo test --all-features --verbose
10 changes: 6 additions & 4 deletions src/postgres/math_udfs.rs
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,13 @@ pub fn acosd(args: &[ArrayRef]) -> Result<ArrayRef> {
}
let result = value.acos().to_degrees();
if result.fract() < 0.9 {
float64array_builder.append_value(result);
if result.fract() < 0.01 {
float64array_builder.append_value(result.floor());
} else {
float64array_builder.append_value(result);
}
} else {
dbg!(&result);
dbg!(&result.round());
float64array_builder.append_value(result.round());
float64array_builder.append_value(result.ceil());
}
Ok::<(), DataFusionError>(())
} else {
Expand Down

0 comments on commit e17bb2e

Please sign in to comment.