Mohammed Atef’s Technical blog

Tips and Tricks

Find SQL Server last service pack installed :  SELECT SERVERPROPERTY (‘productlevel’) as Level

Repeat Header / Keep Header Visible in Tables in RS 2008

How to return multiple values in one column (T-SQL)?

Connect to TFS2010 Server using VS 2008 Client

Microsoft Office 2010: Primary Interop Assemblies Redistributable

SQL Recursive Query

WITH EmployeeLst (ManagerID, EmployeeID, EmployeeName,  Level)
AS (
— Anchor member definition
SELECT e.ManagerID,e.EmployeeID, e.EmployeeName, 0 AS Level
FROM Employees AS e    WHERE e.ManagerID is null
— Recursive member definition
SELECT e.ManagerID,e.EmployeeID, e.EmployeeName,Level + 1
FROM Employees AS e
INNER JOIN EmployeeLst AS lst
ON e.ManagerID = lst.EmployeeID)
SELECT * FROM EmployeeLst


JavaScript Date time control


No comments yet.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

%d bloggers like this: