How to get number of days in a given year?
Answers were Sorted based on User's Feedback
declare @y int;
set @y = 2016;
SELECT DATEDIFF(day,cast(@y as char(4)), cast(@y+1 as char(4))) Days
| Is This Answer Correct ? | 1 Yes | 0 No |
Answer / dinesh rathod
would like to get the total number of days in a year left from the given
| Is This Answer Correct ? | 0 Yes | 0 No |
Answer / pulak
select add_months(trunc(sysdate,'year'),12)-trunc(sysdate,'year') as days from dual;
| Is This Answer Correct ? | 1 Yes | 3 No |
What is the purpose of data source?
What is a Lock and let me know Different types of locks?
how to restart sql server in single user mode? How to start sql server in minimal configuration mode? : Sql server database administration
What are statistics, under what circumstances they go out of date, how do you update them?
what happens on checkpoint? : Sql server database administration
How connect excel to sql server?
Describe in brief system database.
How does SSIS(Sql Server Integration Services) deffer from DTS(Data Transformation Services)?
What is use of attributehierarchyenabled? : sql server analysis services, ssas
What does select 1 mean?
How can you check the level of fragmentation on a table?
What is failover clustering overview?
Oracle (3253)
SQL Server (4518)
MS Access (429)
MySQL (1402)
Postgre (483)
Sybase (267)
DB Architecture (141)
DB Administration (291)
DB Development (113)
SQL PLSQL (3330)
MongoDB (502)
IBM Informix (50)
Neo4j (82)
InfluxDB (0)
Apache CouchDB (44)
Firebird (5)
Database Management (1411)
Databases AllOther (288)