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

feat(cubesql): Support SQL push down for several functions #7431

Merged
merged 1 commit into from
Nov 28, 2023

Conversation

MazterQyou
Copy link
Member

@MazterQyou MazterQyou commented Nov 17, 2023

Check List

  • Tests has been run in packages where changes made if available
  • Linter has been run for changed code
  • Tests for the changes have been added if not covered yet
  • Docs have been added / updated if required

Description of Changes Made

This PR adds SQL push down support for these functions:

  • ASCII
  • ATAN2
  • BTRIM
  • CHAR_LENGTH
  • COT
  • DATEDIFF
  • DEGREES
  • LTRIM
  • RADIANS
  • REPLACE
  • RTRIM
  • SIGN
  • STRPOS
  • TO_CHAR

It also fixes an issue with pushing down DLOG10 in Redshift.

@MazterQyou MazterQyou requested review from a team as code owners November 17, 2023 19:19
Copy link

codecov bot commented Nov 17, 2023

Codecov Report

Attention: 20 lines in your changes are missing coverage. Please review.

Comparison is base (9c0ad07) 47.76% compared to head (b53e79e) 71.67%.
Report is 2 commits behind head on master.

Files Patch % Lines
...t/cubesql/cubesql/src/compile/engine/df/wrapper.rs 61.11% 7 Missing ⚠️
...ubejs-schema-compiler/src/adapter/RedshiftQuery.ts 0.00% 5 Missing ⚠️
...ubejs-schema-compiler/src/adapter/BigqueryQuery.ts 0.00% 4 Missing ⚠️
...bejs-schema-compiler/src/adapter/SnowflakeQuery.ts 0.00% 2 Missing ⚠️
...ubejs-schema-compiler/src/adapter/PostgresQuery.ts 0.00% 1 Missing ⚠️
rust/cubesql/cubesql/src/compile/mod.rs 96.77% 1 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##           master    #7431       +/-   ##
===========================================
+ Coverage   47.76%   71.67%   +23.91%     
===========================================
  Files         155      329      +174     
  Lines       20852    54581    +33729     
  Branches     5369     5369               
===========================================
+ Hits         9960    39123    +29163     
- Misses      10141    14713     +4572     
+ Partials      751      745        -6     
Flag Coverage Δ
cube-backend 48.02% <14.28%> (+0.26%) ⬆️
cubesql 86.31% <84.31%> (?)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@MazterQyou MazterQyou force-pushed the cubesql/push-down-fns branch from 980cf0f to 38333e4 Compare November 18, 2023 10:36
Copy link

vercel bot commented Nov 18, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

8 Ignored Deployments
Name Status Preview Comments Updated (UTC)
examples-angular-dashboard ⬜️ Ignored (Inspect) Visit Preview Nov 28, 2023 7:14pm
examples-react-d3 ⬜️ Ignored (Inspect) Visit Preview Nov 28, 2023 7:14pm
examples-react-dashboard ⬜️ Ignored (Inspect) Visit Preview Nov 28, 2023 7:14pm
examples-react-data-table ⬜️ Ignored (Inspect) Visit Preview Nov 28, 2023 7:14pm
examples-react-highcharts ⬜️ Ignored (Inspect) Visit Preview Nov 28, 2023 7:14pm
examples-react-material-ui ⬜️ Ignored (Inspect) Visit Preview Nov 28, 2023 7:14pm
examples-react-pivot-table ⬜️ Ignored (Inspect) Visit Preview Nov 28, 2023 7:14pm
examples-vue-query-builder ⬜️ Ignored (Inspect) Visit Preview Nov 28, 2023 7:14pm

@MazterQyou MazterQyou force-pushed the cubesql/push-down-fns branch from 38333e4 to 870212c Compare November 18, 2023 10:46
@MazterQyou MazterQyou force-pushed the cubesql/push-down-fns branch from 870212c to d2096c6 Compare November 27, 2023 15:54
@MazterQyou MazterQyou force-pushed the cubesql/push-down-fns branch from d2096c6 to b53e79e Compare November 28, 2023 19:13
@MazterQyou MazterQyou merged commit 79e5ac8 into master Nov 28, 2023
53 of 54 checks passed
@MazterQyou MazterQyou deleted the cubesql/push-down-fns branch November 28, 2023 20:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants