0

I am trying to build a basic web app, and I want to connect it to a database. I have a heroku account so I started trying to get it hooked up to a Postgres DB and ran into issues around SSL and external connections. I tried to update my code and realized that I was missing the references to SQL so tried adding Entity Framework through the package manager.

It goes through the checking compatibility and then tells me

Could not add Entity Framework

I am new to this so not sure what I can provide to help get the answer.

Am I just going about it wrong, is EF not what I need to make a simple DB connection?

marc_s
  • 732,580
  • 175
  • 1,330
  • 1,459
user1735894
  • 323
  • 4
  • 16
  • No, EF is not needed for a "simple DB connection". Entity Framework is a Object Relational Mapping framework. If you just wanted a simple DB connection, then you just need a library that implements the ADO.NET interface, such as [Npgsql](http://www.npgsql.org/doc/index.html). – mason May 15 '17 at 13:59
  • That makes sense. I left out some details then. When I started with postgre DB I went down a code first approach that was using an EF based solution. Upon switching to SQL I used the same code which would be EF. – user1735894 May 15 '17 at 14:03

0 Answers0