Hi guys, I'm just a beginner, so sorry for my question :)
I already tried using char, tinyint, bool and CHECK constraints.
Here is my CHECK constraint:
CHECK (user_type>=0 AND user_type<=1)
But still I can insert values greater than 1, all I want is just 1 s and 0. I will use it as the type of my users. Although I can test this at the front-end level, I still want to do this in the database itself.
Thanks in advance:)
Barry source
share