by Yogesh | May 17, 2016 | Asp .net MVC, Entity Framework Tutorial
Hi, In this blog I am writing sample code to store file name and path into database table using Entity framework code first approach. Download Source Code Step: 1 First Create Controller named Home Controller . Step 2: Create Index.cshtml view into Index Action of...
by Yogesh | Apr 18, 2016 | Asp .net MVC, Entity Framework Tutorial
In this example we are discussing about Code first approach in entity framework , he will see that how we can create database table into database using code first approach. Step 1. Create New Empty MVC Project Step 2. Install Entity framework using package manager...
by Yogesh | Apr 18, 2016 | Asp .net MVC, Entity Framework Tutorial
Step 1: First Create new Project in Visual studio. Step 2: create new asp.net web application Step 3: Create new MVC Empty Project Step 4: First We will write connection string into web.config. In this example I have created a database named MVCEx and a table Login...
by Yogesh | Apr 16, 2016 | Asp .net MVC, Entity Framework Tutorial
Inheritance in EF Inheritance in entity framework ,it is a way to create relationships between database tables.For example primary key and foreign key relationship. Types of Inheritance TPH(Table per Hierarchy) TPC(Table per concrete) TPT(Table per Type) 1. TPH: It...
by Yogesh | Apr 16, 2016 | Entity Framework Tutorial
Entity Framework migration with example This feature is introduced in EF 5 to overcome the problem of database Datainitilzers(Data was lost). We can make changes in database and able to revert back using migrations techniques. Example: Step 1. First we will create two...