write a query that displays every Friday in a year with date?
Answer Posted / ranjan
SELECT C_DATE, TO_CHAR(C_DATE,'DY')
FROM
(
SELECT TO_DATE('01-JAN-2016','DD-MON-YYYY')+LEVEL-1 C_DATE
FROM DUAL
CONNECT BY LEVEL <= (SYSDATE - TO_DATE('01-JAN-2016','DD-MON-YYYY')+1)
)
WHERE TO_CHAR(C_DATE,'DY') = 'FRI'
Is This Answer Correct ? | 11 Yes | 0 No |
Post New Answer View All Answers
How to use group functions in the select clause using oracle?
What is oracle rowcount?
What privilege is needed for a user to create indexes in oracle?
What is oracle database 10g express edition?
What are the various oracle database objects?
How to define a data source name (dsn) in odbc manager?
How to delete multiple rows from a table in oracle?
What is proxy method?
How to do paging with oracle?
How can you merge two tables in oracle?
Can we use oracle pl/sql block in core java? if so how? pls get back to me .....
How would you best determine why your MVIEW couldnt FAST REFRESH?
How to define default values for formal parameters?
What is flashback in Oracle?
How to do clean up if create database failed?