是在“SQL帮助程序”的帮助下实现ASP.NET MVC 5项目的正确方法像3层架构的类。 [英] Is a right way to implement ASP.NET MVC 5 project with the help of "SQL helper" class like 3 tier architecture.

查看:51
本文介绍了是在“SQL帮助程序”的帮助下实现ASP.NET MVC 5项目的正确方法像3层架构的类。的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

之前我正在研究c#(Asp.net)Web应用程序中的3层架构。那个时候我总是在数据访问层使用SQL Helper类进行数据库操作。



现在几天前,我已经转向MVC(5)架构了。在这里,我还在数据访问层实现了sql helper类。



在SQL帮助程序类(如3层体系结构)的帮助下实现ASP.NET MVC 5项目的正确方法。



我尝试了什么:



我在SQL Helper的帮助下创建了测试项目类。这对我来说很好。

Previously I was working on the 3-tier architecture in the c#(Asp.net) web application. That time I have always used "SQL Helper" class at the data access layer for the database manipulation.

Now few days before, I have moved to MVC(5) architecture. Here I have also implement the "sql helper" class at the data access layer.

Is a right way to implement ASP.NET MVC 5 project with the help of "SQL helper" class like 3 tier architecture.

What I have tried:

I have created the test project with the help of "SQL Helper" class. That is working fine for me.

推荐答案

MVC是一个演示框架,你如何实现后端由你决定,没有正确的方式。大多数人正在转向实体框架以访问他们的数据层,所以如果你还没有,那么值得一看。
MVC is a presentation framework, how you implement the back end is up to you, there is no "right" way. Most people are moving on to Entity Framework to access their data layer so it's worth looking at if you haven't already.


这篇关于是在“SQL帮助程序”的帮助下实现ASP.NET MVC 5项目的正确方法像3层架构的类。的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆