[MDEV-12803] Improve function parameter data type control Created: 2017-05-15 Updated: 2017-09-30 Resolved: 2017-05-29 |
|
| Status: | Closed |
| Project: | MariaDB Server |
| Component/s: | GIS, OTHER |
| Fix Version/s: | 10.3.1 |
| Type: | Task | Priority: | Major |
| Reporter: | Alexander Barkov | Assignee: | Alexander Barkov |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | datatype, refactoring | ||
| Issue Links: |
|
||||||||||||||||||||||||||||
| Description |
|
Currently MariaDB has a very relaxed function parameter data type control. It's only prohibited to pass a ROW-type value to a function expecting a scalar parameter, or the other way around. The responsible code resides in:
MariaDB has had mostly general purpose data types so far (except GEOMETRY), so the code assumes that all data types implement all value format methods:
Function parameter data type control needs some improvements, because:
Under terms of this task we'll improve function parameter control methods:
Note, passing GEOMETRY values to functions implemented outside of item_geofunc.h will still be possible for now, e.g.:
This will be fixed under terms of a separate task. |