af20474c67
### What changes were proposed in this pull request? This PR fixes error message shown when changing a column type to year-month/day-time interval type is attempted. ### Why are the changes needed? It's for consistent behavior. Updating column types to interval types are prohibited for V2 source tables. So, if we attempt to update the type of a column to the conventional interval type, an error message like `Error in query: Cannot update <table> field <column> to interval type;`. But, for year-month/day-time interval types, another error message like `Error in query: Cannot update <table> field <column>:<type> cannot be cast to interval year;`. You can reproduce with the following procedure. ``` $ bin/spark-sql spark-sql> SET spark.sql.catalog.mycatalog=<a catalog implementation class>; spark-sql> CREATE TABLE mycatalog.t1(c1 int) USING <V2 datasource implementation class>; spark-sql> ALTER TABLE mycatalog.t1 ALTER COLUMN c1 TYPE interval year to month; ``` ### Does this PR introduce _any_ user-facing change? No. ### How was this patch tested? Modified an existing test. Closes #32978 from sarutak/err-msg-interval. Authored-by: Kousuke Saruta <sarutak@oss.nttdata.com> Signed-off-by: Max Gekk <max.gekk@gmail.com> |
||
---|---|---|
.. | ||
benchmarks | ||
src | ||
pom.xml |