Answer Posted / muhammadrashidmughal
select *
from table
where date between '01/01/2003' and '12-31-2008'
or
today is 09-08-2008
select *
from table
where year(date)=year(getdate)-5 and month(date)= '08' and
day(date) ='09'
or
select *
from table
where date >='09-08-2003'
and date<='09-08-2008'
| Is This Answer Correct ? | 5 Yes | 1 No |
Post New Answer View All Answers
How to list all user names in a database?
How to remove duplicate rows from table except one?
What is the maximum length of an alert name?
What is the difference between sdf and mdf?
What is difference between cte and view?
How to grant a permission in ms sql server using "grant execute" statements?
Explain the usage of floor function in sql server.
What is normalization? Explain different forms of normalization?
What is meant by Active-Passive and Active-Active clustering setup?
What is multi-statement table-value user-defined function?
Explain subquery and state its properties?
What is attribute relationships, why we need it? : sql server analysis services, ssas
What is bit data type?
What is meant by referential integrity?
What are the underflow and overflow behaviors on float literals?