Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

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


Please Help Members By Posting Answers For Below Questions

Which dictionary tables and/or views would you look at to diagnose a locking issue?

1905


Can we convert a date to char in oracle and if so, what would be the syntax?

1004


What do you mean by redo log file mirroring?

1022


What is private procedure oracle?

1006


What is the difference between PFILE and SPFILE in Oracle?

1054


How many types of segments in Oracle?

1062


How does the on-delete-cascade statement work?

1098


what happened to the global index when I truncate the data in one of the partition?

2014


why should i declare foreign key constraint as self relation instead of binary relation in tables ?

2035


What is ASM (Automatic Storage Management) in Oracle?

1186


what is the difference between substr and instr function in oracle?

1077


What is oracle database 10g express edition?

1114


How to add a new column to an existing table in oracle?

1131


How to handle a single quote in oracle sql?

1035


What is the relation of a user account and a schema?

1125