Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

How to get number of days in a given year?

Answer Posted / rajkumar

DECLARE @IsLeapYear        BIT




    SET @IsLeapYear = 0
    IF (YEAR( @pDate ) % 4 = 0 AND YEAR( @pDate ) % 100 != 0) OR
        YEAR( @pDate ) % 400 = 0
        SET @IsLeapYear = 1




    select 365 + @IsLeapYear

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is sqlservr.exe - process - sql server (sqlex?press)?

1059


How to disable stored procedure sql server?

1532


How to convert character strings into numeric values?

1035


How do you create an execution plan?

885


What are the different types of columns types constraints in the sql server?

1012


Define compound operators?

863


Can a database be shrunk to 0 bytes, if not, why?

1041


Explain transaction server explicit transaction?

879


What happens if null values are involved in string operations?

921


Tell me what do you understand by a view? What does the with check option clause for a view do?

956


How to provide login information for a new odbc dsn?

981


What is difference between drop truncate and delete?

1020


Explain about link server in sql server?

1008


How to create a new table in a given schema?

1114


What are the different types of data sources in ssrs?

188