List:General Discussion« Previous MessageNext Message »
From:hsv Date:May 23 2013 12:30am
Subject:RE: Version 5.6.2-m5 Boolean Datatype
View as plain text  
>>>> 2013/05/22 21:17 +0000, Rick James >>>>
In query syntax, TRUE is the same as 1; FALSE is the same as 0.
<<<<<<<<
and UNKNOWN is NULL. (I actually have used a three-state comparison.)

It has been suggested that one who wants a real two-state field use the type
CHAR(0) NULL.

>>>>>>>>
If you have more 'flags', consider the SET datatype.  (Yeah, it is somewhat clumsy.) 
<<<<<<<<
And SET is mapped onto some integer, even as ENUM is. BIT, now deprecated I understand,
would have been the perfect type to map ENUM onto.

Thread
Version 5.6.2-m5 Boolean DatatypeNeil Tompkins22 May
  • Re: Version 5.6.2-m5 Boolean DatatypeHartmut Holzgraefe22 May
Re: Version 5.6.2-m5 Boolean DatatypeNeil Tompkins22 May
  • Re: Version 5.6.2-m5 Boolean Datatypeshawn green22 May
    • Re: Version 5.6.2-m5 Boolean DatatypeNeil Tompkins22 May
      • Re: Version 5.6.2-m5 Boolean DatatypeDarryle Steplight22 May
Re: Version 5.6.2-m5 Boolean DatatypeWm Mussatto22 May
  • RE: Version 5.6.2-m5 Boolean DatatypeRick James22 May
    • RE: Version 5.6.2-m5 Boolean Datatypehsv23 May