Yes/No Datatype

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • wisni1rr
    New Member
    • Nov 2011
    • 78

    Yes/No Datatype

    I am new to mySQL and am working on making a replacement database for out current access database.

    I am trying to plan for the yes/no datatype in access. From what I understand, the mySQL equivelent is the TINYINT datatype.

    Using the TINYINT datatype, what value would be considered "true/yes"? Would it be "1 for yes/true" and "2 No/False"?

    Is it truly down to what I make it? Just a matter of consistency.

    Thanks for taking the time to answer this!!!
  • Rabbit
    Recognized Expert MVP
    • Jan 2007
    • 12517

    #2
    The equivalent would be a bit(1), where the valid values are 0-1. And yes, it comes down to what you make it.

    Comment

    • vslsanthosh
      New Member
      • Feb 2012
      • 3

      #3
      try ENUM data type,,.

      Comment

      • wisni1rr
        New Member
        • Nov 2011
        • 78

        #4
        @vslsanthosh

        Thank you for the suggestion; I am also using that approach in certain circumstances.

        Comment

        Working...