Constraints: Your Last Line of Data Integrity

Application code is where you validate input. Constraints are where you make sure the database refuses bad data even when the application code is wrong, and it will be wrong eventually.