From: Patrick Put Date: 2009-01-22T22:24:57+09:00 Subject: How to use the type in the Mysql::Field object? I'm trying to do something like this (not really, I want to use the type info instead of just displaying it...): fields = $db.list_fields(tablename).fetch_fields fields.each do |field| puts "Type = #{field.type} (#{field.type.class})" end Result: Type = 1 (Fixnum) Type = 253 (Fixnum) Type = 2 (Fixnum) Type = 254 (Fixnum) etc. How can I translate the first part to something presentable? I cannot find any information on how to translate the integer values to something like FLOAT, SMALLINT, TIMESTAMP, etc. Does anybody have some information about this? -- Posted via http://www.ruby-forum.com/.