This question relates to a new class library project created in Visual Studio 2012.
I have added a SQL Server view to my entity framework model.
In the properties of the PromisedDate
column, I have changed Nullable from (None)
to False
as there will never be a null value returned in this column. I have double-checked there are no null values with a select statement.
However, even after a save, closing all open tabs in Visual Studio and doing a full clean and rebuild of the solution, PromisedDate
is still a DateTime?
and I have to keep using .Value
in code to get the value of it.
It's frustrating, what am I doing wrong?!
Here is a screenshot of the generated .CS file: