What are the disadvantages to do so?
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
The disadvantage of allowing a column to be null impacts business logic – null means effectively there is no value associated, but there could be. If that’s not correct for your business rules, then the column shouldn’t allow for null values to exist within it.
NULL values are known in some cases to be expensive to query execution, and some databases won’t evaluate two columns with values of null being equivalent.
BTW: Although you could set a DEFAULT constraint to make the column value to be null, that’s more work than is necessary. There are three components to a column definition when creating or altering a table: