write a query that displays every Friday in a year with date?

Answer Posted / basanti meher

SELECT A_DATE, TO_CHAR(A_DATE,'DY')
FROM
(
SELECT TO_DATE('01-JAN-2016','DD-MON-YYYY')+LEVEL-1 A_DATE
FROM DUAL
CONNECT BY LEVEL <= (366)
)
WHERE TO_CHAR(A_DATE,'DY') = 'FRI'

Is This Answer Correct ?    2 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How to define a variable to match a table column data type?

586


Is there any way to find out when one specific table/view/M-view is used last time. i.e. when one specific object is used in any SELECT statement.

866


How to pass a cursor variable to a procedure?

566


How to find out what oracle odbc drivers are installed?

582


What is a nested table?

633






What is bulk load in oracle?

601


What is the string concatenation operator in oracle?

574


I have a database backup file in .db (ext) form how to conver it into .dmp (ext.) for oracle database

1637


How to establish administrator authentication to the server?

565


How to specify default values in insert statement using oracle?

570


How to import one table back from a dump file?

599


How to loop through a cursor variable?

574


What is define in oracle?

573


src name sex a,male b,female c,male d,female Required output : male female a,b c,d tried pivot but was not successfull select * from src pivot (max(name) for sex in ('MALE','FEMALE'));

1186


What is difference between sid and service name in oracle?

523