5 messages in com.mysql.lists.perlRe: DECIMAL col type bug in DBD::mysq...
FromSent OnAttachments
Ray Zimmerman01 Dec 2005 11:21 
Selke, Gisbert W.02 Dec 2005 08:37 
Ray Zimmerman02 Dec 2005 09:07 
Patrick Galbraith12 Dec 2005 16:25 
Ray Zimmerman12 Dec 2005 16:32 
Subject:Re: DECIMAL col type bug in DBD::mysql w/mysql 5
From:Ray Zimmerman (rz@cornell.edu)
Date:12/02/2005 09:07:54 AM
List:com.mysql.lists.perl

On Dec 2, 2005, at 11:37 AM, Selke, Gisbert W. wrote:

I don't think it's DBD::mysql. http://bugs.mysql.com/bug.php? id=14923 has an entry from the MySQL people that may be an explanation. Base line: "There is no standard C type for fixed point numeric type, so MySQL server returns decimal as a string." This comes also up in MySQL QueryBrowser, so it's not just DBD::mysql.

While this may be related, I think it is a different issue. I'm not sure where the bug is (server or DBD::mysql), but apparently the server knows that the column is a DECIMAL type as opposed to VARCHAR, since SHOW COLUMNS FROM <table> does say DECIMAL.

Whether or not the server returns values for decimal columns as strings is not the issue. It's the fact that when I query for the column type I'm being told it's a VARCHAR column, when it's actually a DECIMAL column. I still believe this is a bug, but without knowing how DBI sets these values, I don't know if it's a bug in the driver or in the server.

Ray