List:General Discussion« Previous MessageNext Message »
From:Paul DuBois Date:October 20 1999 11:41am
Subject:Re: enum type
View as plain text  
At 12:05 PM -0500 10/20/99, Bogdan Paduraru wrote:
>Hello mySQLists,
>I wanna to perform with enum type an action like this :
>    select concat(field1,'.',field2) as field3 from table.
>field1 is of enum type containing a char string, field2 is of int type.
>I want to concatenate the int value corresponding to the enum type of
>field1(and not the char string) with the int value of field2. Is this
>possible? And how can I do it?

If you mean that you want to concatenate the numeric value of field1,
use CONCAT(field1+0,'.',field2).  The "+0" will force field1 to be used
as a number.

Paul DuBois, paul@stripped
enum typeBogdan Paduraru20 Oct
  • Re: enum typePaul DuBois20 Oct
  • enum typeMichael Widenius20 Oct