TwilioDevEd / appointment-reminders-csharp

Example App and Tutorial content for Appointment Reminders in C# | .NET
https://www.twilio.com/docs/tutorials/walkthrough/appointment-reminders/csharp/mvc
MIT License
16 stars 11 forks source link

appointment-reminders.mdf missing #2

Open craigaporter opened 8 years ago

craigaporter commented 8 years ago

Hello,

Maybe I'm being simple, but I can't find appointment-reminders.mdf in the git repo?

nebtrx commented 8 years ago

Hey @craigaporter, I didn't worked on this one, but as we are using EF top versions and Code First approach you just run the migrations.

BNeiman commented 4 years ago

To fix this, I created the database "appointment-reminders" and modified the web.config connectionStrings / DefaultConnection from this: "Data Source=(LocalDb)\MSSQLLocalDB;AttachDbFilename=|DataDirectory|\appointment-reminders.mdf;Initial Catalog=appointment-reminders;Integrated Security=True"

To this: "Data Source=(localdb)\MSSQLLocalDB;Initial Catalog=appointment-reminders;Integrated Security=True;Connect Timeout=30;Encrypt=False;TrustServerCertificate=False;ApplicationIntent=ReadWrite;MultiSubnetFailover=False"

Then run Package Manager Update-Database

ediganeelima commented 4 years ago

Had the same issue. App_Data folder was missing (even if it appers in the solution, its not includd in the project). Select the Web project, right click and select Add Asp.Net folder -> App_Data This would add the folder. Then run Update-database command in the Nugget console. This would resolve the issue.

** I also ran Update-Package as part of trial and error, while fixing this. Not sure if this is needed.