Bug #9259 getObject() returns byte array for date

Submitted: 18 Mar 2005 1:42 Modified: 12 Apr 2005 13:57
Reporter: Jonathan Louie Email Updates:
Status: Duplicate Impact on me:
None 
Category:MySQL Server Severity:S2 (Serious)
Version:3.1.7 OS:Linux (RedHat 9)
Assigned to: Assigned Account CPU Architecture:Any

[18 Mar 2005 1:42] Jonathan Louie
Description:
When running query SELECT DATE(time) AS date, COUNT(*) FROM events GROUP BY date; I try to get the date from column 1.  ResultSet.getMetaData().getColumnTypeName() returns CHAR, which doesn't seem right.  Also, ResultSet.getObject() returns a byte array.  However, doing ResultSet.getDate() seems to work fine.

How to repeat:
Create a table with a datetime column called time and run the query above.

Suggested fix:
ResultSet.getObject() should return a java.sql.Date.
[18 Mar 2005 1:45] Mark Matthews
This is a duplicate of BUG#8868 which is already fixed for the upcoming 3.1.8 release.

Portions of this website are copyright © 2001, 2002 The PHP Group

Page generated in 0.039 sec. using MySQL 8.4.7-u6-cloud

Timestamp references displayed by the system are UTC.
Content reproduced on this site is the property of the respective copyright holders.
It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.