Month: October 2017

Code First Entity Framework – ASP.NET MVC TUTORIALS

Entity Framework is an object-relational mapper that enables .NET developers to work with relational data using domain-specific objects. It eliminates the need for most of the data-access code that developers usually need to write. Entity framework have two approaches to work. 1 is database first and 2nd is code first approach. In this tutorial, we’ll discuss about code first entity framework. Code First Entity Framework Now we know about code first entity framework approach in asp.net mvc. In the next tutorial, we’ll discuss about seeding the...

Read More

Database First vs Code First Approach – ASP.NET MVC TUTORIALS

Entity Framework is an object-relational mapper that enables .NET developers to work with relational data using domain-specific objects. It eliminates the need for most of the data-access code that developers usually need to write. Entity framework have two approaches to work. 1 is database first and 2nd is code first approach. Learn database first vs code first approach. Database First vs Code First Approach You know about database first and code first approach in asp.net mvc now. In the next tutorial, we’ll discuss about code first...

Read More

Entity Framework in ASP.NET MVC – ASP.NET MVC TUTORIALS

Entity Framework is an object-relational mapper that enables .NET developers to work with relational data using domain-specific objects. It eliminates the need for most of the data-access code that developers usually need to write. Learn more about what is entity framework in asp.net mvc and how it works. ENTITY FRAMEWORK IN ASP.NET MVC You know about working of entity framework in asp.net mvc now. In the next tutorial, we’ll discuss about database first vs code first...

Read More

Learn top 10 most used SQL Queries

Some of the most important and mostly used SQL Server queries you should learn while going to work with C#, ASP .Net. Here’s are all the top 10 most used sql queries you should never miss. Just follow the article below. Learn top 10 most used SQL Queries 1. SQL query to fetch value in tblUsersDay but not in tblUsersNight. In SQL Server, PostgreSQL, and SQLite, this can be done using the except keyword as follows:   select * from tblUsersDay                     except                     select * from tblUsersNight; 2. Add the 3 more when Nmber column value is greater then zero otherwise add 2. update tblNum set Nmbr = case when Nmbr > 0 then Nmbr+3 else Nmbr+2 end; 3. Alpha-Numeric Sorting in SQL Server. SELECT Name FROM  [Amatya].[dbo].[tblTagNo] ORDER BY         CAST(SUBSTRING(Name, 1,PATINDEX('%[A-Za-z]%', Name)-1) AS INT)  DESC --First numeric sorting         ,SUBSTRING(Name, PATINDEX('%[A-Za-z]%', Name),1) --Sort by Alphabets OR In Ascending SELECT Name FROM  [PAMSVNEW].[dbo].[DemoTable] ORDER BY         CAST(SUBSTRING(Name, 1,PATINDEX('%[A-Za-z]%', Name)-1) AS INT)  --First numeric sorting         ,SUBSTRING(Name, PATINDEX('%[A-Za-z]%', Name),1) --Sort by Alphabets 4. When we want to copy table from one Table to another new table CREATE TABLE [dbo].[tblSubTaskSurveyEvalutaion] (         ActivityTd int not null,...

Read More

Razor View Syntax in ASP.NET MVC – ASP.NET MVC TUTORIALS

The Razor syntax is based on the C# programming language, and that’s the language that’s used most often with ASP.NET Web Pages. However, the Razor syntax also supports the Visual Basic language, and everything you see you can also do in Visual Basic. Learn more about how razor view syntax in asp.net mvc works. RAZOR VIEW SYNTAX IN ASP.NET MVC You know about working of razor view syntax in asp.net mvc now. In the next tutorial, we’ll discuss about entity...

Read More