Sean-Kenneth-Doherty opened a new pull request, #22287:
URL: https://github.com/apache/datafusion/pull/22287

   ## Which issue does this PR close?
   
   - Closes #22258.
   
   ## Rationale for this change
   
   PostgreSQL-compatible `regexp_replace` should honor the multiline flag `m` 
so anchors like `^` can match after newlines. The issue report covers 
`regexp_replace(E'a\nb', '^b', 'x', 'm')`, which should produce `a\nx`.
   
   Current main already returns the PostgreSQL-compatible result, so this PR 
adds explicit regression coverage to keep that behavior from drifting.
   
   ## What changes are included in this PR?
   
   - Adds Rust unit coverage for scalar/static `regexp_replace` with flag `m`.
   - Adds sqllogictest coverage for `m` and `gm` multiline flag behavior.
   
   ## Are these changes tested?
   
   - `cargo fmt --all`
   - `TMPDIR=/home/sean/Projects/datafusion-regexp-replace/target/tmp cargo 
test -p datafusion-functions 
regex::regexpreplace::tests::test_static_pattern_regexp_replace_multiline_flag 
-- --nocapture`
   - `TMPDIR=/home/sean/Projects/datafusion-regexp-replace/target/tmp cargo 
test --profile=ci --test sqllogictests -- regexp/regexp_replace.slt`
   - `TMPDIR=/home/sean/Projects/datafusion-regexp-replace/target/tmp cargo 
clippy --all-targets --all-features -- -D warnings`
   - `git diff --check`
   
   ## Are there any user-facing changes?
   
   No behavior change intended. This adds regression coverage for 
PostgreSQL-compatible multiline `regexp_replace` behavior.
   


-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to