Commit 7497682
authored
fix: Throw USER_ERROR instead of FUNCTION_IMPLEMENTATION_MISSING for unsupported parameters (#26553)
## Description
Throwing proper error code for better error classification.
## Motivation and Context
We see queries failing with `Unsupported type parameters
(BoundVariables{typeVariables={T=array(varchar)}, longVariables={}}) for
presto.default.approx_distinct<T>(T):bigint` where parmater isn't
supported. This is simply user error (also the error message suggests
so). Throwing user error code in this case reudce unnecessary retry,
miscategorization and send proper signal to users.
## Impact
None
## Test Plan
Existing
```
== NO RELEASE NOTE ==
```1 parent b824c5b commit 7497682
File tree
1 file changed
+2
-2
lines changed- presto-main-base/src/main/java/com/facebook/presto/operator/scalar
1 file changed
+2
-2
lines changedLines changed: 2 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
29 | 29 | | |
30 | 30 | | |
31 | 31 | | |
32 | | - | |
| 32 | + | |
33 | 33 | | |
34 | 34 | | |
35 | 35 | | |
| |||
119 | 119 | | |
120 | 120 | | |
121 | 121 | | |
122 | | - | |
| 122 | + | |
123 | 123 | | |
124 | 124 | | |
0 commit comments