i am using asp.net application to enter and view data in sql server database.
i am not sure what data type to use in sql server to allow booleans?
when entering data into the database the users will be clicking on a check box to signify true/false.
- how do i implement bools with sql server?
- how do i give the ability to the user in formview to enter true/false?
As the others said, you can use
BITdatatype.However, be warned that if you put
BITinto a table, and you want only binary values, disableNULL.If you allow
NULLin a bit field it will actually be trinary and allow three values.