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...

How to display all Friday's in a year with date?

Answer Posted / nihar meher

declare
a date;
b date;
c number(15);
begin
select trunc(sysdate,'yyyy') into a from dual;
select add_months(trunc(sysdate,'yyyy'),12)-1 into b from dual;
c:=b-a;
for i in 1..c
loop
if to_char(a,'dy')='fri'
then
dbms_output.put_line(a);
end if;
a:=a+1;
end loop;
end;

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

what are all the different types of indexes? : Sql dba

1046


Does a primary key have to be a number?

963


Does sql view stored data?

955


What is the use of nvl function?

1197


What is an index in sql with example?

970


How many triggers can be applied on a table?

932


How sql query is executed?

1127


What is a table partition?

1127


What is pl sql block in dbms?

1001


How is a process of pl/sql compiled?

1158


Define select, insert, create, delete, update, drop keywords

1047


What is indexing in sql and its types?

1078


Why indexing is needed?

983


Are subqueries faster than joins?

1020


Any attempt to navigate programmatically to disabled form in a call_form stack is allowed?

1098