Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Any New Column is Null value in Entity Framework

I am adding a new column to exiting database table with values, but when I used the entity framework model, the column data value return Null, however its has a real value in database.

How solve this problem?

like image 839
Mohammad Diab Avatar asked Sep 12 '25 23:09

Mohammad Diab


1 Answers

If you are using LINQ for data retrieval:

Double click and open edmx -> right click and select update from database -> select refresh tab and select your table and click ok.

The above will update your dbcontext file.

enter image description here

enter image description here

If you are using stored procedure, you will have to update the complex type of your stored procedure

like image 147
Jibin Balachandran Avatar answered Sep 15 '25 12:09

Jibin Balachandran