shardingsphere
shardingsphere copied to clipboard
Support parsing SQL Server SELECT TRIM
Fixes #29162.
Changes proposed in this pull request:
Task
This issue is to support more SQL Server sql parsing, as follows:
SELECT TRIM( '.,! ' FROM ' # test .') AS Result
SELECT TRIM(LEADING '.,! ' FROM ' .# test .') AS Result
SELECT TRIM(TRAILING '.,! ' FROM ' .# test .') AS Result
SELECT TRIM(BOTH '123' FROM '123abc123') AS Result
Before committing this PR, I'm sure that I have checked the following options:
- [ ] My code follows the code of conduct of this project.
- [ ] I have self-reviewed the commit code.
- [ ] I have (or in comment I request) added corresponding labels for the pull request.
- [ ] I have passed maven check locally :
./mvnw clean install -B -T1C -Dmaven.javadoc.skip -Dmaven.jacoco.skip -e. - [ ] I have made corresponding changes to the documentation.
- [ ] I have added corresponding unit tests for my changes.
Hi @zzzk1, thank you for your contribution. Please solve ci exception on your local machine.
@strongduanmu pls take a look
Hi @zzzk1, thank you for your contribution. I leave some comment, please take a look.
Hi @zzzk1, can you take a look at https://github.com/apache/shardingsphere/pull/30270, I made some minor optimizations. You can get this code conduct from doc - https://shardingsphere.apache.org/community/cn/involved/conduct/code/#g4-%E8%A7%84%E8%8C%83.
Hi @zzzk1, can you take a look at #30270, I made some minor optimizations. You can get this code conduct from doc - shardingsphere.apache.org/community/cn/involved/conduct/code/#g4-%E8%A7%84%E8%8C%83.
sorry about that i will be prudently next