问题描述
您好我有一个视图,它包含22个字段。我的数据库完全正常化。我有13个表来保存这22个字段。我使用Code First方法和ViewModel进行插入。我做了同样的事情,如下面链接中提到的插入过程
http://www.codeproject.com/Tips/651495/InsertingIGN-into -Multiple-Tables-using-Code-Fir
现在插入工作正常现在我想在MVC4中使用codefirstapproach和ViewModel进行UPDATE,DELETE,INDEX过程我不知道这该怎么做 。对于Index我写内连接查询。但是对于更新和删除过程?我不知道如何从多个能够更新和删除过程中检索数据。请任何人给我一个例子的解决方案。
预先谢谢。
Hi i have one view and it contain 22 fields. My DB is fully normalized. I have 13 tables to save those 22 fields. I used Code First approach and ViewModel for insertion . I did same as like which is mentioned in the below link for insertion process
http://www.codeproject.com/Tips/651495/Inserting-Data-into-Multiple-Tables-using-Code-Fir
Now insertion is working fine now i want to do UPDATE, DELETE, INDEX process using codefirstapproach and ViewModel in MVC4 i donno how to do this . For Index i write Inner Join query . But for Update and Delete Process? i donno how to retreive data from multiple able for update and delete process. Please any one give me solution with one example.
Advance Thanks.
推荐答案
这篇关于如何使用Code第一种方法和MVC4中的viewmodel进行更新删除?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!