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

[FEATURE] CBRT scalar function in new engine #1054

Closed
acarbonetto opened this issue Nov 8, 2022 · 3 comments
Closed

[FEATURE] CBRT scalar function in new engine #1054

acarbonetto opened this issue Nov 8, 2022 · 3 comments
Labels

Comments

@acarbonetto
Copy link
Collaborator

Is your feature request related to a problem?
The following statement fails because CBRT is not implemented in the new v2 engine

{
    "query": "SELECT CBRT(value);"
}

error:

{
  "error": {
    "reason": "Invalid SQL query",
    "details": "Cannot invoke \"com.alibaba.druid.sql.ast.statement.SQLTableSource.getAlias()\" because the return value of \"com.alibaba.druid.sql.dialect.mysql.ast.statement.MySqlSelectQueryBlock.getFrom()\" is null",
    "type": "NullPointerException"
  },
  "status": 400
}

What solution would you like?
Something like: https://www.w3resource.com/PostgreSQL/cbrt-function.php

What alternatives have you considered?

{
    "query": "SELECT CBRT(value) FROM bigint;"
}

does work, but this is using the legacy engine for SQL

Do you have any additional context?
n/a

@acarbonetto acarbonetto added enhancement New feature or request untriaged labels Nov 8, 2022
@Yury-Fridlyand
Copy link
Collaborator

WIP: Bit-Quill#166

@margarit-h
Copy link
Contributor

PR: #1081

@margarit-h
Copy link
Contributor

PR for adding CBRT() to the PPL: #1097

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants