2

In my .edmx my date field has DefaultValue set to (None) but when i create a new record 01/01/0001 value appear . Also in my SQL , there is no default value . How can disable it ????

1 Answer 1

3

Make your DateTime field nullable. Which is DateTime? MyDate {get; set;}

Sign up to request clarification or add additional context in comments.

1 Comment

i dont want to accept nulls , also when i update my model the "?" is removed because my field does not allow nulls

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.