Showing posts with label MS SQL SERVER 2005. Show all posts
Showing posts with label MS SQL SERVER 2005. Show all posts

Wednesday, July 13, 2011

On clusters, the SQL Server Browser listens on which port?

Answer: IP_ANY

Explanation: In a cluster, the browser listens on the IP_ANY port, since this is not a cluster aware service.

Ref: SQL Server Browser Service - http://msdn.microsoft.com/en-us/library/ms181087.aspx

Tuesday, August 24, 2010

The ultimate Wedding Query... (SQL Style)

I am running the following SQL query among the databases instances I managed in different MS SQL servers for fun....

At that point, I should say that the desired "tuple" has not yet been found :-( . . . .




Details of the SQL query follow:

--
-- Funny query
-- Date: 25 August 2010
--
-- The ultimate Wedding Query................ (SQL Style)

-- HUSBANDS QUERY

CREATE PROCEDURE MyMarriage(BrideGroom Male (25),Bride Female(20) )
AS BEGIN
SELECT Bride FROM Beautiful_ Brides
WHERE FatherInLaw = 'Millionaire'
AND Count(Car) > 20 AND HouseStatus ='ThreeStoreyed'
AND BrideEduStatus IN (B.TECH ,BE ,Degree ,MCA ,MiBA, PHD) AND Having Brothers= Null
AND Sisters =Null


SELECT Gold, Shares, Cash, Car, BankBalance
FROM FatherInLaw
UPDATE MyBankAccout
SETMyBal = MyBal + FatherInLawBal
UPDATE MyLocker
SET MyLockerContents = MyLockerContents + FatherInLawGold
INSERT INTOMyCarShed VALUES('Porsche')
END
GO

-- Then the wife writes the below query:
DROP HUSBAND;
Commit;

-- (-: