Saturday, 2 December 2017

MSSQL - Fix Error - The name "false" is not permitted in this context. Valid expressions are constants, constant expressions, and (in some contexts) variables. Column names are not permitted.

Error

The name "false" is not permitted in this context. Valid expressions are constants, constant expressions, and (in some contexts) variables. Column names are not permitted.

Watch solution on YouTube


To fix it replace

ALTER TABLE Product
ADD isFinalSale bit NOT NULL DEFAULT(false)
GO

with

ALTER TABLE Product
ADD isFinalSale bit NOT NULL DEFAULT(0)
GO

No comments:

Post a Comment