Access database from multiple applications


I have an application for Windows Forms (C #) and an asp.NET web application that provides access to a Sql Server database. I want to centralize access to the database. What metadologies should I follow? What is the general approach to this problem?

  • Writing DALs and model libraries and using them in both applications
  • Writing a WCF service, including the DAL model, and using this service with both applications
  • None of the above?

Can you give me an idea?
Thank.

+3
source share
5 answers

, SOA ( WCF WebServices > DAL), DAL dll Windows Forms exe. UI.

, :

  • , URL-, - .

  • , , , ( , intercace).

  • , HTTP , dll.

  • , , ASP.NET, Windows Forms, .

0

WCF. , ( , ) , , (), , .

+2

, WCF.

, WCF; Entity Framework, .

, , - , , , , , .

, , , , , - - .

, .

+1

1 , .
2 WCF , , . .

0

( WCF, DAL).

0

All Articles