Saturday 29 September 2012

Basics of Triggers in SQL Server

Querying Microsoft SQL Server : Basics of Triggers in SQL Server: SQL Triggers:  A trigger is a procedural code like stored procedure that is automatically executed on certain actions (like insert, de...

Basics of Indexes in SQL Server

Querying Microsoft SQL Server : Basics of Indexes in SQL Server: Indexes in SQL Server: If you see a book, in last of book an index is provided that has some titles and page numbers. You don’t need ...

Saturday 22 September 2012

Connection String from Visual Studio

Querying Microsoft SQL Server : Connection String from Visual Studio: Connection String: A connection string contains connection information need to connect with data source.You can connect your project with ...

Data Types in SQL Server

Querying Microsoft SQL Server : Data Types in SQL Server: Data Type Description Remarks BIGINT Used for large Integer data.(Range -2^63  to 2^63-1) It takes 8 B...

Functions in SQL Server

 Functions in SQL Server: Functions in SQL Server In SQL Server functions are subrotienes that encapsulate a group of T-SQL statements for reuse.SQL Server pro...

Error Handling in T-SQL

 Error Handling in T-SQL: Error handling in T-SQL: Error handling in T-SQL is similer to other programming languages as C#,C++,Java.A group of statements  encl...

Wednesday 19 September 2012

Defining Variables

Querying Microsoft SQL Server : Defining Variables: Defining Variables in SQL Server: Like other programming languages T-SQL allows to defining your variables. A variable is known as lo...

Querying Microsoft SQL Server : Certifications

Querying Microsoft SQL Server : Certifications: If you  would like to obtain a certification for SQL Server. The latest certification Microsoft offer for SQL Server are the MC...

Stored Procedures in SQL Server

Querying Microsoft SQL Server : Stored Procedures in SQL Server: Stored Procedure: Stored Procedure is a powerful part of SQL Server. It is group of T-SQL statements compiled into single execution ...

Control Statements in T-SQL

Querying Microsoft SQL Server : Control Statements in T-SQL: Control statements are used to control execution flow within a T-SQL.Here I provides some example on control statements. ·          ...

Saturday 8 September 2012

Create database to test Queries of this blog..........

Run this script:


CREATE DATABASE dbTest;

CREATE TABLE Person
(
pid INT IDENTITY(1,1),
name VARCHAR(200) NOT NULL,
dob DATETIME NULL,
occupation varchar(100) NULL,
address VARCHAR(200),
city VARCHAR(100),
state VARCHAR(100),
isBlock BIT,
PRIMARY KEY(PID)
)

USE [dbTest]
GO
/****** Insert Data into Person table   ******/
SET IDENTITY_INSERT [dbo].[Person] ON
INSERT [dbo].[Person] ([pid], [name], [dob], [occupation], [address], [city], [state], [isBlock]) VALUES (1, N'Abhishek', CAST(0x00007A1B00000000 AS DateTime), N'Student', N'E-56', N'Delhi', N'Delhi', 0)
INSERT [dbo].[Person] ([pid], [name], [dob], [occupation], [address], [city], [state], [isBlock]) VALUES (2, N'Ram', CAST(0x00006E2500000000 AS DateTime), N'DBA', N'PritVihar', N'Lucknow', N'U.P.', 0)
INSERT [dbo].[Person] ([pid], [name], [dob], [occupation], [address], [city], [state], [isBlock]) VALUES (3, N'Abhijit', CAST(0x00007E8300000000 AS DateTime), N'J.DBA', N'', NULL, NULL, 1)
SET IDENTITY_INSERT [dbo].[Person] OFF


Friday 7 September 2012

Welcome Querying SQL.

Hi,
I extend a hearty welcome on my Blog.I hope this blog be helpful for those who preparing Microsoft SQL Server certifications and also for those who are hungry to learn querying SQL server. 



Links:


Y