Description
Rewrite validation dynamic parameters by moving type checking of dynamic parameters to TypeCoercion.
Introduce type compatibly checks for dynamic parameters:
OK: SELECT * FROM t WHERE int_col = ?:int OK: SELECT * FROM t WHERE int_col = ?:smallint SELECT * FROM t WHERE int_col = cast(?:smallint, int) ERR: SELECT * FROM t WHERE int_col = ?:str ERR: SELECT * FROM t WHERE str_col = ?:int ERR: SELECT 1 + ?:str ERR: SELECT ?:str + ?:str
Attachments
Issue Links
- is related to
-
IGNITE-19353 Sql. Incorrect type conversion for dynamic parameters - CAST operation ignores type precision.
- Resolved
-
IGNITE-18645 Sql. Type System. Reject plans with not matching dynamic parameters types during query validation.
- Open
- links to