[MDEV-6018] Strange interaction of SQL_MODE=ANSI and partition by TIMESTAMP Created: 2014-04-03 Updated: 2022-09-08 |
|
| Status: | Open |
| Project: | MariaDB Server |
| Component/s: | None |
| Affects Version/s: | 5.5.36, 10.0.10 |
| Fix Version/s: | 5.5 |
| Type: | Bug | Priority: | Minor |
| Reporter: | Hartmut Holzgraefe | Assignee: | Unassigned |
| Resolution: | Unresolved | Votes: | 0 |
| Labels: | upstream | ||
| Environment: |
Linux |
||
| Description |
|
see also http://bugs.mysql.com/bug.php?id=72222 [3 Apr 14:21] Hartmut Holzgraefe Description: On closer look it turned out that if the table was created with SQL_MODE='ANSI_QUOTES' and indeed using ANSI quotes around identifiers The error message thrown on any attempt to open the table is ERROR 1486 (HY000): Constant, random or timezone-dependent expressions in (sub)partitioning function are not allowed although UNIX_TIMESTAMP(timestamp_column) should not be How to repeat: FLUSH TABLES; SET @@SQL_MODE='ANSI_QUOTES'; SET @@SQL_MODE=''; FLUSH TABLES; Suggested fix: [3 Apr 14:27] Hartmut Holzgraefe The problem seems to be in the ansi qotes in PARTITION BY RANGE ( UNIX_TIMESTAMP("t")) only, when removing these everything works fine |
| Comments |
| Comment by Hartmut Holzgraefe [ 2022-05-01 ] |
|
Not reproducible in MariaDB 10.2.10 (the oldest 10.2 release I still have at hand) or later. So with 10.1 now being beyond EOL we can probably just close this one. |