LINQ to Entities does not recognize the method 'System.String ToString()' method in MVC 4

前端 未结 4 1239
温柔的废话
温柔的废话 2020-12-03 02:35

I\'m working with MVC 4 and I have to update my database using Code First Migrations. What I\'m trying to do is to select records from a database table, and insert them int

4条回答
  •  轻奢々
    轻奢々 (楼主)
    2020-12-03 03:09

    What if... you use:

    Value = c.id + "",
    

    instead of

    Value = c.id.ToString(),
    

    Edit

    With this option, you are not retrieving all data from Database

提交回复
热议问题