Error "1660 Illegal value used as argument of dynamic column function" is not helpful

Bug #778915 reported by Philip Stoev
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
MariaDB
Won't Fix
Wishlist
Michael Widenius

Bug Description

Error " 1660 Illegal value used as argument of dynamic column function" shows up when one tries to assign two values to the same dynamic column within a single statement. The same operation would be allowed in an INSERT, where the last value would be used. So, either make dynamic columns behave as INSERT, or provide a better error message, e.g. "duplicate field name"

For example:

 SELECT COLUMN_CREATE( 5 , 1 , 5 , 1 ) ;

Changed in maria:
milestone: none → 5.3
assignee: nobody → Michael Widenius (monty)
summary: - Error 1660 Illegal value used as argument of dynamic column function is
- not exact
+ Error "1660 Illegal value used as argument of dynamic column function"
+ is not helpful
description: updated
Revision history for this message
Michael Widenius (monty) wrote :

This is a restriction of the current implementation. I will for now document this in the manual.
The idea is that in the future it will behave as INSERT in this case.

Changed in maria:
importance: Undecided → Wishlist
status: New → Won't Fix
Revision history for this message
Michael Widenius (monty) wrote :

For now, you can only get the error: "Illegal value used as argument of dynamic column function" if you provide a too big column number (> 65535) or if you have the same column number twice in a COLUMN_CREATE or COLUM_ADD function.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.