I want to save my value as a boolean in my mysql database. But somehow Iam not able to save it , mysql automatically saves it of the type tinyInt.Also tell me the default values for boolean. how we pass the values?
In MySQL BOOLEAN
type is a synonym for TINYINT
. There is no dedicated BOOLEAN
type.
The vaules accepeted, are those for TINYINT
i.e. 0 for false, 1-255 (preferably 1) for true.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With