How to display all Friday's in a year with date?
Answer Posted / dinesh
DECLARE
c date:='01-JAN-15';
d date:='31-DEC-15';
a number(10);
BEGIN
a:=d-c;
FOR i in 1..a
LOOP
IF to_char(c,'DY')='FRI' THEN
DBMS_OUTPUT.PUT_LINE('THIS IS FRIDAY DATE:='|| ' '|| c);
END IF;
c:=c+1;
END loop;
END;
| Is This Answer Correct ? | 3 Yes | 0 No |
Post New Answer View All Answers
Can we change the table name in sql?
what is a primary key? : Sql dba
What is indexing oracle sql?
What does truncate mean in sql?
What is the difference between delete and truncate commands?
What is recursive join in sql?
What are the types of join in sql?
What are the benefits of pl/sql packages?
How to Declare Fixed Length String Value In PL SQL
How do I make sql search faster?
What is pivot in sql?
What is trigger in pl sql with examples?
What are pl/sql packages?
What are the possible values for the boolean data field?
what is msql? : Sql dba