doc-fr icon indicating copy to clipboard operation
doc-fr copied to clipboard

cannot save boolean false in Mysql database

Open vickson5118 opened this issue 2 years ago • 2 comments

From manual page: https://php.net/language.types.boolean


When I use an object containing a bool attribute, it is impossible to save the false value of the boolean in the database

vickson5118 avatar Dec 08 '22 23:12 vickson5118

MySQL does not have a bool datatype.

yassiNebeL avatar Dec 19 '22 20:12 yassiNebeL

You should use a TINYINT sql datatype instead

dbomard avatar Dec 01 '23 13:12 dbomard