Bug #28509 strange behaviour: passing a decimal value to PS
Submitted: 18 May 2007 7:13 Modified: 18 Jun 2007 16:47
Reporter: Ramil Kalimullin Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Server: Prepared statements Severity:S3 (Non-critical)
Version:5.0 OS:Any
Assigned to: Ramil Kalimullin

[18 May 2007 7:13] Ramil Kalimullin
Description:
Passing a decimal value to 
"create table a select ?" 
leads to "Unknown error".

How to repeat:
mysql> prepare s from "create table a select ?";
Query OK, 0 rows affected (0.00 sec)
Statement prepared

mysql> set @a=1.0;
Query OK, 0 rows affected (0.00 sec)

mysql> execute s using @a;
ERROR 1105 (HY000): Unknown error
[18 May 2007 13:17] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/26985

ChangeSet@1.2484, 2007-05-18 18:16:51+05:00, ramil@mysql.com +3 -0
  Fox for bug #28509: strange behaviour: passing a decimal value to PS
  
  Set parameter's type to Item::DECIMAL_ITEM assigning a decimal value.
[6 Jun 2007 16:54] Bugs System
Pushed into 5.1.20-beta
[6 Jun 2007 16:57] Bugs System
Pushed into 5.0.44
[18 Jun 2007 16:47] Paul Dubois
Noted in 5.0.44, 5.1.20 changelogs.

Passing a DECIMAL value as a parameter of a statement prepared with
PREPARE resulted in an error.