How to find no of saturdays in a month using single sql ?
Answer Posted / nagaraju
select count(*) from (
select trunc(to_date(sysdate,'DD/MM/rrrr'),'mm') +rownum -1 dates
from dual connect by level <=Add_Months(trunc(to_date(sysdate,'DD/MM/rrrr'),'mm'),1) - trunc(to_date(sysdate,'DD/MM/rrrr'),'mm')
)
where
to_char(dates,'DY')='SAT'
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
Give the different types of rollback segments.
How to filter out duplications in the returning rows using oracle?
Difference between open_form and call_form in oracle.
Explain the use of indexes option in imp command.
When do you get a .pll extension in oracle?
How to convert characters to times in oracle?
Explain parameter file in oracle.
What is oracle in java?
How to define and use table alias names in oracle?
How to get a create statement for an existing table?
Is it possible to set second Primary Key Constraint in a table in Oracle Database ?
What is the disadvantage of User defind function?
What are the different types of database objects?
How to create a temporary table in oracle?
What is a nested table and how is it different from a normal table?