kosiew opened a new pull request, #14970:
URL: https://github.com/apache/datafusion/pull/14970

   ## Which issue does this PR close?
   
   Closes #14969.
   
   <!--
   We generally require a GitHub issue to be filed for all bug fixes and 
enhancements and this helps us generate change logs for our releases. You can 
link an issue to this PR using the GitHub syntax. For example `Closes #123` 
indicates that this PR will close issue #123.
   -->
   
   ## Rationale for this change
   
   The `to_char` function was incorrectly returning `NULL` for valid `DATE` 
values due to improper handling of the `DATE` type. This fix ensures that 
`to_char` correctly formats non-null `DATE` values while preserving `NULL` 
values as expected.
   
   ## What changes are included in this PR?
   
   - Fixed the `to_char` function to properly process `DATE` values.
   - Added slt test cases to verify correct behavior when formatting `DATE` 
values.
   
   ## Are these changes tested?
   
   Yes, new test cases have been added to confirm that:
   1. `to_char` correctly formats valid `DATE` values.
   2. `NULL` values remain unaffected.
   
   ## Are there any user-facing changes?
   
   No breaking changes. Users will now see correctly formatted `DATE` values 
when using `to_char`, instead of unexpected `NULL` results.
   
   <!--
   If there are any breaking changes to public APIs, please add the `api 
change` label.
   -->


-- 
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