While you are not wrong, James, is the length member suppose to denote the maximum length of data contained in result's specified column. NOTE: The result's. I.e. why give such an arbitrary number of bytes/length when no ENUM's or SET's are even in the result. The point being, even if you create a table containing 10 INT columns, the result of "show columns from" should show the Type column length of 3 with a maximum data allocation for the 10 rows of 30 bytes, and not ~2MB, as is currently the case.
And even, in a worse case, MySQL Dev decided to give the length back as the maximum "potential" length, who determined 196605 should be the "magic number"? An ENUM can have 64K values, each of which can be a text value/label of at least 64 characters, thus a "magic number" should be at least megs in size to "play it safe". Thus, such an approach is simply put, stupid. Ideally, as was the case in previous versions of MySQL, the Type column's Length should be given in context of the result, i.e. if there is an ENUM in the column list and it has the longest "type" description, the Type column's length should reflect its contained data size. Kind Regards SciBit MySQL Team http://www.scibit.com > > -----Original Message----- > From: "James Harvard" <[EMAIL PROTECTED]> > To: "SciBit MySQL Team" <[EMAIL PROTECTED]> > CC: "mysql@lists.mysql.com" <mysql@lists.mysql.com> > Subject: [Spam-Junk]Re: MySQL 5.0.22 and show columns bug? > Sent: Thu, 06 Jul 2006 13:50:33 GMT > Received: Thu, 06 Jul 2006 13:50:29 GMT > Read: Sat, 30 Dec 1899 00:00:00 GMT > Although I know nothing about C I imagine this is because the 'type' column > can contain all the possible values from an ENUM or SET field. > James Harvard > > At 10:30 am +0000 6/7/06, SciBit MySQL Team wrote: > >Since a couple of recent stable versions back (and more recently, MySQL > >5.0.22), MySQL has been returning the column length (C API) of the 'Type' > >column of a "show columns from.." statement as being 196605 (almost 192KB), > >when this column only really contains data in the region of 10 bytes > > -- > MySQL General Mailing List > For list archives: http://lists.mysql.com/mysql > To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED] > > > -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED]