SQL Server Archive

How To Create Non Clustered Primary Key in SQL Server

In this tutorial i am going to explain about How To Create Non Clustered Primary Key in SQL Server. In my previous tutorial i have explained about Create primary key,composite key in Entity framework | Use of key attribute in ASP.Net MVC How to add create composite primary key in sql server Alter table to

How to add create composite primary key in sql server

In this tutorial i am going to explain about how to add create composite primary key in sql server. In my previous tutorial i have explained about Alter table to add primary key in sql server Create table with primary key in sql server example Create primary key,composite key in Entity framework | Use of

Alter table to add primary key in sql server

In this tutorial i am going to explain about Alter table to add primary key in sql server 2012. In my previous tutorial i have explained about ASP.NET MVC client side validation using data annotations CRUD operations using Entity Framework Database First Approach and MVC 4 Insert Update Delete(crud operations) in MVC 4 using Stored Procedure

Create table with primary key in sql server example

In this blog i am going to explain about how to Create table with primary key in sql server example. You can check some of my previous sql server blog posts. SQLServer IDENTITY Column with text Sql Select statement with auto generated row id SQL Query to backup database in sql server Create or reset the

Sql script(query) to get the columns with datatype of tables with default values

In this tutorial i am going to explain about sql script or query to get the columns of a particular table or all the tables in the database along with datatype and default values of that particular column like null,not null,empty or getdate() etc..In my previous article i have explained about Visual Studio Keyboard Shortcuts

SQL Script to drop multiple tables,procedures at once in sql server

In this article i am going to explain about how to drop multiple tables,procedures or functions at once. Sometimes we supposed to drop multiple tables. For explanation purpose i have created two tables namely testtable1 and testtable2 and i have created two procedures namely GetTestTable1 and GetTestTable2. Now i will explain the syntax and the

Sql Server 2005/2008 Cursor Example|Cursor Example in Sql Server 2005/2008|Create cursor in sql server

Introduction: In my previous article I have explained about SQL Query to backup database in sql server, SQL query to extract file names from a html content, How to set deadlock priority in sql server, Find count of each characters in a string in SQL Server, Use of SET NOCOUNT in sql server, Different Isolation

How to create table in sql server 2008

In this article i am going to explain about how to create table in sql server 2008. “Create Table” Statement is uesd to create table in sql server. In sql server tables are organised as rows and columns.And each column will have name and the datatype it accepts. So creating table in sql server we

Pagination Query in Sql server

I was asked a question or a series of questions, “How would you do paging in a SQL? How would you do this with a lot of records, say, 10,000 or more?” I thought about answers. To be more precise, I thought of more questions and this got me thinking, “This must be a common

Sql Query to fetch in between records from a table

In this article i am going to expalin the query used to fetch the inbetween records from a table For example if my requirement is to fetch from 30th to 50th record from citymaster table then i can use the below query. We can achieve it using OFFSET FETCH clause.The OFFSET-FETCH clause provides you with