Click here to Skip to main content
15,888,984 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Facing a strange problem with EF at the moment. I have a table in database with nvarchar(MAX) data type and is a nullable field. While updating the entries in the table when I assign null to this field its not saving that null, rather keeping the old value intact. But saving the empty string in it works.


Any solution or guidance will be really appreciated.

What I have tried:

Have tried google and tried
UseCSharpNullComparisonBehavior
and
UseDatabaseNullSemantics
Posted
Comments
Richard Deeming 30-Mar-17 15:04pm    
Have you tried using SQL Profiler (or MiniProfiler[^]; or context.Database.Log) to see the update queries being generated by EF?

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900