Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make division-by-zero behavior configurable #213

Open
knassre-bodo opened this issue Jan 14, 2025 · 0 comments
Open

Make division-by-zero behavior configurable #213

knassre-bodo opened this issue Jan 14, 2025 · 0 comments
Labels
documentation Improvements or additions to documentation effort - medium mid-sized issue with average implementation time/difficulty enhancement New feature or request user feature Adding a new user-facing feature/functionality

Comments

@knassre-bodo
Copy link
Contributor

Currently, the behavior when division-by-zero occurs is purely controlled by the database being used to execute PyDough code. This should, instead, be configurable like some other settings through PyDoughConfigs. The configurable settings for division-by-zero can include:

  • An option to let the database resolve it
  • An option to always convert a / b to a / KEEP_IF(b, b != 0)
  • An option to always convert a / b to CASE WHEN b = 0 THEN 0 ELSE a / b END

This configurable option should be noted in the documentation.

@knassre-bodo knassre-bodo added documentation Improvements or additions to documentation enhancement New feature or request user feature Adding a new user-facing feature/functionality effort - medium mid-sized issue with average implementation time/difficulty labels Jan 14, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation effort - medium mid-sized issue with average implementation time/difficulty enhancement New feature or request user feature Adding a new user-facing feature/functionality
Projects
None yet
Development

No branches or pull requests

1 participant