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

Failed to analyze trim function for integer as parameter #95

Open
MajeedB opened this issue Sep 19, 2024 · 2 comments
Open

Failed to analyze trim function for integer as parameter #95

MajeedB opened this issue Sep 19, 2024 · 2 comments

Comments

@MajeedB
Copy link

MajeedB commented Sep 19, 2024

Hello Team,
Unable validate below expression.

Select trim(5)

Expected : Tool should catch exception. It should throw exception like parameter is incorrect.

Actual : simply validating as correct expression

Please resolve this issue.

@dion-ricky
Copy link
Contributor

Tested working on my setup:
image

As you can see the analyzer raises a SqlException with message saying No matching signature for function TRIM for argument types: INT64. ...

The analyzed query is exactly as you've provided, here's the watcher from my debugger showing the value of analyzed query:
image

Is there something that i'm missing? Please let me know.

@MajeedB
Copy link
Author

MajeedB commented Oct 3, 2024

I am trying catch the error using below code

analyzer. analyzeStatements(myQuery, this.Catlog, true)

Unable to catch the error msg.

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

No branches or pull requests

2 participants